-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
78 lines (68 loc) · 1.23 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
cmake_minimum_required(VERSION 2.8.3)
project(glove_acquisition)
set(CMAKE_CXX_FLAGS "-std=c++11")
find_package(catkin REQUIRED
COMPONENTS
roscpp
std_msgs
geometry_msgs
message_generation
)
add_message_files(
DIRECTORY msg
FILES
GloveIMU.msg
GloveIMUArray.msg
)
generate_messages(
DEPENDENCIES
std_msgs
geometry_msgs
)
include_directories(include
${catkin_INCLUDE_DIRS}
)
set(LIB_GLOVE glove_core)
catkin_package(
INCLUDE_DIRS include
LIBRARIES ${LIB_GLOVE}
CATKIN_DEPENDS
roscpp
std_msgs
geometry_msgs
message_runtime
)
set(BIN_TALKER glove_talker)
set(BIN_LISTENER glove_listener)
# Talker
add_executable(${BIN_TALKER}
src/glove_talker.cpp
src/glove_core.cpp
)
target_link_libraries(${BIN_TALKER}
${catkin_LIBRARIES}
)
add_dependencies(${BIN_TALKER}
${catkin_EXPORTED_TARGETS}
)
# Listener
add_executable(${BIN_LISTENER}
src/glove_listener.cpp
src/glove_core.cpp
)
target_link_libraries(${BIN_LISTENER}
${catkin_LIBRARIES}
)
add_dependencies(${BIN_LISTENER}
${catkin_EXPORTED_TARGETS}
)
# Exported library
add_library(${LIB_GLOVE}
src/glove_core.cpp
)
target_link_libraries(${LIB_GLOVE}
${catkin_LIBRARIES}
)
add_dependencies(${LIB_GLOVE}
${catkin_EXPORTED_TARGETS}
)