diff options
-rw-r--r-- | .bzrignore | 1 | ||||
-rw-r--r-- | CMakeLists.txt | 20 | ||||
-rw-r--r-- | ipecamera/CMakeLists.txt | 3 |
3 files changed, 23 insertions, 1 deletions
@@ -17,3 +17,4 @@ CMakeFiles cmake_install.cmake Makefile *.so.* +install_manifest.txt diff --git a/CMakeLists.txt b/CMakeLists.txt index 7664481..40d7396 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,6 +9,7 @@ find_package(PkgConfig REQUIRED) #Check in sibling directory pkg_check_modules(UFODECODE ufodecode REQUIRED) +pkg_check_modules(FASTWRITER fastwriter REQUIRED) set(HEADERS pcilib.h pci.h register.h kmem.h irq.h dma.h event.h default.h tools.h error.h) add_definitions("-fPIC --std=c99 -Wall -O2 -pthread") @@ -18,7 +19,7 @@ add_subdirectory(ipecamera) add_subdirectory(pcitool) add_library(pcilib SHARED pci.c register.c kmem.c irq.c dma.c event.c default.c tools.c error.c) -target_link_libraries(pcilib ufodecode dma ipecamera) +target_link_libraries(pcilib ufodecode fastwriter dma ipecamera) add_dependencies(pcilib dma ipecamera) set_target_properties(pcilib PROPERTIES @@ -36,3 +37,20 @@ target_link_libraries(pci pcilib pcitool) # LINK_FLAGS "-Wl,pcitool/libpcitool.a" #) + +if(NOT DEFINED BIN_INSTALL_DIR) + set(BIN_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/bin") +endif(NOT DEFINED BIN_INSTALL_DIR) + + +install(TARGETS pcilib + LIBRARY DESTINATION lib${LIB_SUFFIX} +) + +install(TARGETS pci + DESTINATION ${BIN_INSTALL_DIR} +) + +install(FILES pcilib.h + DESTINATION include +) diff --git a/ipecamera/CMakeLists.txt b/ipecamera/CMakeLists.txt index 029993c..87699fa 100644 --- a/ipecamera/CMakeLists.txt +++ b/ipecamera/CMakeLists.txt @@ -6,3 +6,6 @@ set(HEADERS ${HEADERS} ipecamera.h model.h reader.h events.h data.h public.h pri add_library(ipecamera STATIC ipecamera.c model.c reader.c events.c data.c) +install(FILES ipecamera.h + DESTINATION include +) |