-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
30 lines (21 loc) · 948 Bytes
/
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
cmake_minimum_required(VERSION 2.8.3)
project(roboclaw_driver)
## Find catkin and any catkin packages
find_package(catkin REQUIRED COMPONENTS roscpp message_generation geometry_msgs nav_msgs tf)
add_message_files(FILES RoboClawState.msg)
generate_messages(DEPENDENCIES std_msgs)
find_package(PkgConfig REQUIRED)
pkg_check_modules(LIBUSB1 libusb-1.0 REQUIRED)
include_directories(${LIBUSB1_INCLUDE_DIRS})
## Declare a catkin package
catkin_package(CATKIN_DEPENDS roscpp message_runtime geometry_msgs nav_msgs tf)
include_directories(include ${catkin_INCLUDE_DIRS})
file(GLOB_RECURSE HEADER_FILES include/*.h)
add_library(roboclaw src/RoboClaw.cpp)
target_link_libraries(roboclaw ${LIBUSB1_LDFLAGS} ${roscpp_LIBRARIES})
set(SOURCE_FILES
${PROJECT_SOURCE_DIR}/src/RoboclawNode.cpp
)
add_executable(roboclaw_driver ${SOURCE_FILES})
target_link_libraries(roboclaw_driver ${catkin_LIBRARIES})
target_link_libraries(roboclaw_driver roboclaw)