-
Notifications
You must be signed in to change notification settings - Fork 2
/
CMakeLists.txt
73 lines (63 loc) · 1.74 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
cmake_minimum_required(VERSION 2.8.3)
project(aruco_cube_ros)
find_package(catkin REQUIRED COMPONENTS
roscpp
rospy
std_msgs
geometry_msgs
sensor_msgs
tf2
tf2_ros
tf2_geometry_msgs
cv_bridge
dynamic_reconfigure
message_generation
nodelet
)
add_service_files(
FILES
GetPose.srv
)
# GENERATE MESSAGE FILES
generate_messages(
DEPENDENCIES
geometry_msgs
std_msgs
)
#add dynamic reconfigure api
generate_dynamic_reconfigure_options(
cfg/ArucoCube.cfg
)
find_package(OpenCV 3 REQUIRED)
catkin_package(
INCLUDE_DIRS include
#LIBRARIES aruco_cube_nodelet
#CATKIN_DEPENDS message_runtime geometry_msgs std_msgs tf2_ros tf2 nodelet
)
# ADD NODES
add_executable(aruco_cube_node src/aruco_cube_node.cpp)
target_link_libraries(aruco_cube_node ${catkin_LIBRARIES} ${OpenCV_LIBS} ${OpenCV_LIBRARIES})
add_dependencies(aruco_cube_node ${PROJECT_NAME}_gencfg ${catkin_EXPORTED_TARGETS} ${${PROJECT_NAME}_EXPORTED_TARGETS})
# ADD NODELET LIBRARIES
add_library(aruco_cube_nodelet src/aruco_cube_nodelet.cpp)
target_link_libraries(aruco_cube_nodelet ${catkin_LIBRARIES} ${OpenCV_LIBS} ${OpenCV_LIBRARIES})
add_dependencies(aruco_cube_nodelet ${PROJECT_NAME}_gencfg ${catkin_EXPORTED_TARGETS} ${${PROJECT_NAME}_EXPORTED_TARGETS})
include_directories(
include
${catkin_INCLUDE_DIRS}
)
install(TARGETS aruco_cube_node
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
install(TARGETS aruco_cube_nodelet
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
)
install(DIRECTORY launch/
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/launch
PATTERN ".svn" EXCLUDE
)
install(DIRECTORY config/
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/config
PATTERN ".svn" EXCLUDE
)