|
1 |
| -################################################################################ |
2 |
| -# CMake |
3 |
| -################################################################################ |
4 |
| -cmake_minimum_required(VERSION 2.8.3) |
5 |
| -project(robotis_controller) |
6 |
| - |
7 |
| -set(CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}") |
8 |
| - |
9 |
| -################################################################################ |
10 |
| -# Packages |
11 |
| -################################################################################ |
12 |
| -find_package(catkin REQUIRED COMPONENTS |
13 |
| - roscpp |
14 |
| - roslib |
15 |
| - sensor_msgs |
16 |
| - std_msgs |
17 |
| - robotis_controller_msgs |
18 |
| - robotis_framework_common |
19 |
| - cmake_modules |
20 |
| -) |
21 |
| - |
22 |
| -################################################################################ |
23 |
| -# Declare ROS messages, services and actions |
24 |
| -################################################################################ |
25 |
| - |
26 |
| -################################################################################ |
27 |
| -# Declare ROS dynamic reconfigure parameters |
28 |
| -################################################################################ |
29 |
| - |
30 |
| -################################################################################ |
31 |
| -# Catkin specific configuration |
32 |
| -################################################################################ |
33 |
| -catkin_package( |
34 |
| - INCLUDE_DIRS include |
35 |
| - LIBRARIES robotis_controller |
36 |
| - CATKIN_DEPENDS roscpp roslib sensor_msgs std_msgs robotis_framework_common |
37 |
| -) |
38 |
| - |
39 |
| -################################################################################ |
40 |
| -# Build |
41 |
| -################################################################################ |
42 |
| -include_directories( |
43 |
| - include |
44 |
| - ${catkin_INCLUDE_DIRS} |
45 |
| -) |
46 |
| - |
47 |
| -add_library(robotis_controller src/robotis_controller/robotis_controller.cpp) |
48 |
| -add_dependencies(robotis_controller ${catkin_EXPORTED_TARGETS}) |
49 |
| -target_link_libraries(robotis_controller yaml-cpp ${catkin_LIBRARIES}) |
50 |
| - |
51 |
| -################################################################################ |
52 |
| -# Install |
53 |
| -################################################################################ |
54 |
| -install(TARGETS robotis_controller |
55 |
| - ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} |
56 |
| - LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} |
57 |
| - RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION} |
58 |
| -) |
59 |
| - |
60 |
| -install(DIRECTORY include/${PROJECT_NAME}/ |
61 |
| - DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION} |
62 |
| -) |
63 |
| - |
64 |
| -################################################################################ |
65 |
| -# Test |
66 |
| -################################################################################ |
| 1 | +################################################################################ |
| 2 | +# CMake |
| 3 | +################################################################################ |
| 4 | +cmake_minimum_required(VERSION 2.8.3) |
| 5 | +project(robotis_controller) |
| 6 | + |
| 7 | +set(CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}") |
| 8 | + |
| 9 | +################################################################################ |
| 10 | +# Packages |
| 11 | +################################################################################ |
| 12 | +find_package(catkin REQUIRED COMPONENTS |
| 13 | + roscpp |
| 14 | + roslib |
| 15 | + sensor_msgs |
| 16 | + std_msgs |
| 17 | + robotis_controller_msgs |
| 18 | + robotis_framework_common |
| 19 | + cmake_modules |
| 20 | +) |
| 21 | + |
| 22 | +################################################################################ |
| 23 | +# Declare ROS messages, services and actions |
| 24 | +################################################################################ |
| 25 | + |
| 26 | +################################################################################ |
| 27 | +# Declare ROS dynamic reconfigure parameters |
| 28 | +################################################################################ |
| 29 | + |
| 30 | +################################################################################ |
| 31 | +# Catkin specific configuration |
| 32 | +################################################################################ |
| 33 | +catkin_package( |
| 34 | + INCLUDE_DIRS include |
| 35 | + LIBRARIES robotis_controller |
| 36 | + CATKIN_DEPENDS roscpp roslib sensor_msgs std_msgs robotis_framework_common |
| 37 | +) |
| 38 | + |
| 39 | +################################################################################ |
| 40 | +# Build |
| 41 | +################################################################################ |
| 42 | +include_directories( |
| 43 | + include |
| 44 | + ${catkin_INCLUDE_DIRS} |
| 45 | +) |
| 46 | + |
| 47 | +add_library(robotis_controller src/robotis_controller/robotis_controller.cpp) |
| 48 | +add_dependencies(robotis_controller ${catkin_EXPORTED_TARGETS}) |
| 49 | +target_link_libraries(robotis_controller yaml-cpp ${catkin_LIBRARIES}) |
| 50 | + |
| 51 | +################################################################################ |
| 52 | +# Install |
| 53 | +################################################################################ |
| 54 | +install(TARGETS robotis_controller |
| 55 | + ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} |
| 56 | + LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} |
| 57 | + RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION} |
| 58 | +) |
| 59 | + |
| 60 | +install(DIRECTORY include/${PROJECT_NAME}/ |
| 61 | + DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION} |
| 62 | +) |
| 63 | + |
| 64 | +################################################################################ |
| 65 | +# Test |
| 66 | +################################################################################ |
0 commit comments