-
Notifications
You must be signed in to change notification settings - Fork 25
/
CMakeLists.txt
104 lines (93 loc) · 2.05 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
cmake_minimum_required(VERSION 2.8.3)
project(st_handeye)
add_compile_options(-std=c++11)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_LIST_DIR}/cmake")
find_package(G2O REQUIRED)
find_package(VISP REQUIRED)
find_package(Eigen3 REQUIRED)
find_package(OpenCV REQUIRED)
find_package(Boost REQUIRED filesystem program_options)
include_directories(
include
${G2O_INCLUDE_DIRS}
${VISP_INCLUDE_DIRS}
${EIGEN3_INCLUDE_DIRS}
${Boost_INCLUDE_DIRS}
${OpenCV_INCLUDE_DIRS}
)
link_directories(${G2O_LIBRARY_DIRS})
###########
## Build ##
###########
add_library(st_handeye_graph
src/st_handeye_graph.cpp
)
target_link_libraries(st_handeye_graph
${Boost_LIBRARIES}
${OpenCV_LIBRARIES}
${G2O_TYPES_DATA}
${G2O_CORE_LIBRARY}
${G2O_STUFF_LIBRARY}
${G2O_SOLVER_PCG}
${G2O_SOLVER_CSPARSE}
${G2O_SOLVER_CHOLMOD}
${G2O_TYPES_SLAM3D}
${G2O_TYPES_SLAM3D_ADDONS}
)
add_library(st_handeye_graph_xray
src/st_handeye_graph_xray.cpp
)
target_link_libraries(st_handeye_graph_xray
${Boost_LIBRARIES}
${OpenCV_LIBRARIES}
${G2O_TYPES_DATA}
${G2O_CORE_LIBRARY}
${G2O_STUFF_LIBRARY}
${G2O_SOLVER_PCG}
${G2O_SOLVER_CSPARSE}
${G2O_SOLVER_CHOLMOD}
${G2O_TYPES_SLAM3D}
${G2O_TYPES_SLAM3D_ADDONS}
)
add_library(st_handeye_visp
src/st_handeye_visp.cpp
)
target_link_libraries(st_handeye_visp
${Boost_LIBRARIES}
${OpenCV_LIBRARIES}
${VISP_LIBRARIES}
)
# handeye_simulation
add_executable(handeye_simulation
src/handeye_simulation.cpp
)
target_link_libraries(handeye_simulation
st_handeye_graph
st_handeye_visp
)
add_dependencies(handeye_simulation
st_handeye_graph
st_handeye_visp
)
# handeye_simulation_xray
add_executable(handeye_simulation_xray
src/handeye_simulation_xray.cpp
)
target_link_libraries(handeye_simulation_xray
st_handeye_graph_xray
)
add_dependencies(handeye_simulation_xray
st_handeye_graph_xray
)
# calibrate
add_executable(calibrate
src/calibrate.cpp
)
target_link_libraries(calibrate
st_handeye_graph
st_handeye_visp
)
add_dependencies(calibrate
st_handeye_graph
st_handeye_visp
)