forked from bosch-ros-pkg/photo
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
81 lines (66 loc) · 1.63 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
cmake_minimum_required(VERSION 2.8.3)
project(gphoto2_ros)
find_package(catkin REQUIRED COMPONENTS
message_generation
roscpp
self_test
sensor_msgs
std_msgs
std_srvs
)
find_package(OpenCV REQUIRED)
find_package(PkgConfig REQUIRED)
pkg_check_modules(gphoto2 REQUIRED libgphoto2)
add_service_files(FILES
Capture.srv
GetConfig.srv
SetConfig.srv
DownloadPictures.srv
)
generate_messages(DEPENDENCIES
std_msgs
sensor_msgs
)
catkin_package(
INCLUDE_DIRS include
LIBRARIES gphoto2_ros
CATKIN_DEPENDS roscpp std_msgs sensor_msgs self_test
DEPENDS OpenCV gphoto2
)
include_directories(
include
${catkin_INCLUDE_DIRS}
${OpenCV_INCLUDE_DIRS}
${gphoto2_INCLUDE_DIRS}
)
add_library(gphoto2_ros
src/libphoto2/photo_reporter.cpp
src/libphoto2/photo_camera_list.cpp
src/libphoto2/photo_camera.cpp
src/libphoto2/photo_image.cpp
)
add_executable(photo_node src/photo_node/photo_node.cpp)
add_executable(test_photo src/test_photo/test_photo.cpp)
add_dependencies(photo_node photo_generate_messages_cpp)
add_dependencies(test_photo photo_generate_messages_cpp)
target_link_libraries(gphoto2_ros
${OpenCV_LIBRARIES}
)
target_link_libraries(photo_node
gphoto2_ros
${catkin_LIBRARIES}
${gphoto2_LIBRARIES}
)
target_link_libraries(test_photo
gphoto2_ros
${catkin_LIBRARIES}
${OpenCV_LIBRARIES}
)
install(TARGETS gphoto2_ros photo_node test_photo
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
install(DIRECTORY include/${PROJECT_NAME}/
DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}
)