-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
53 lines (44 loc) · 1.33 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
cmake_minimum_required(VERSION 2.8.3)
project(raw_video_stream)
find_package(catkin REQUIRED COMPONENTS
roscpp
rospy
cv_bridge
image_transport
camera_info_manager
sensor_msgs
nodelet
roslaunch
)
roslaunch_add_file_check(launch)
find_package(OpenCV REQUIRED)
if (OpenCV_VERSION VERSION_EQUAL "3")
add_definitions("-DOPENCV3=1")
endif()
find_package(Boost REQUIRED COMPONENTS thread)
catkin_package(
CATKIN_DEPENDS roscpp sensor_msgs
DEPENDS OpenCV
INCLUDE_DIRS include
LIBRARIES ${PROJECT_NAME}
)
include_directories(
${catkin_INCLUDE_DIRS}
${OpenCV_INCLUDE_DIRS}
)
include_directories(include)
add_library(${PROJECT_NAME}
src/nodelets/process_file.cpp
src/libraw_video_stream/advertisement_checker.cpp
)
add_dependencies(${PROJECT_NAME} ${PROJECT_NAME}_gencfg)
target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES} ${Boost_LIBRARIES} ${OpenCV_LIBRARIES})
# Standalone node
add_executable(raw_video_stream_exe src/nodes/raw_video_stream.cpp)
target_link_libraries(raw_video_stream_exe ${PROJECT_NAME} ${catkin_LIBRARIES} ${Boost_LIBRARIES} ${OpenCV_LIBRARIES})
SET_TARGET_PROPERTIES(raw_video_stream_exe PROPERTIES OUTPUT_NAME raw_video_stream)
install(TARGETS raw_video_stream_exe
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
install(DIRECTORY launch
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION})