-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathCMakeLists.txt
169 lines (139 loc) · 3.38 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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
cmake_minimum_required(VERSION 3.5)
project(db-CBS)
find_package(Boost 1.58 REQUIRED COMPONENTS program_options)
find_package(Eigen3 REQUIRED)
find_package(PkgConfig)
pkg_check_modules(YAML REQUIRED yaml-cpp)
find_package(fcl REQUIRED)
add_subdirectory(dynoplan)
# set(ompl_ROOT ${}/k_cbs/ompl)
# find_package(ompl)
# pkg_check_modules(OMPL REQUIRED ompl)
# Enable C++17 and warnings
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra")
add_subdirectory(k_cbs/Kinodynamic-Conflict-Based-Search EXCLUDE_FROM_ALL)
include_directories(
${EIGEN3_INCLUDE_DIR}
${CMAKE_SOURCE_DIR}/deps/libMultiRobotPlanning/include
${FCL_INCLUDE_DIRS}
${CMAKE_SOURCE_DIR}/k_cbs/Kinodynamic-Conflict-Based-Search/src
${CMAKE_BINARY_DIR}/k_cbs/Kinodynamic-Conflict-Based-Search/src
)
add_library(motion_planning_common
src/robots.cpp
)
target_include_directories(motion_planning_common
PRIVATE ${CMAKE_BINARY_DIR}/deps/fcl/include
PRIVATE ${CMAKE_SOURCE_DIR}/deps/fcl/include
)
set_property(TARGET motion_planning_common PROPERTY POSITION_INDEPENDENT_CODE ON)
## ompl
add_executable(main_ompl
src/main_ompl.cpp
# src/robots.cpp
)
target_link_libraries(main_ompl
motion_planning_common
${Boost_LIBRARIES}
${YAML_LIBRARIES}
ompl
${FCL_LIBRARIES}
)
target_include_directories(main_ompl PUBLIC
${YAML_INCLUDE_DIRS}
${FCL_INCLUDE_DIRS}
)
## kcbs
add_executable(main_kcbs
src/main_kcbs.cpp
# src/robots.cpp
)
target_link_libraries(main_kcbs
motion_planning_common
${Boost_LIBRARIES}
${YAML_LIBRARIES}
ompl
${FCL_LIBRARIES}
)
target_include_directories(main_kcbs PUBLIC
${YAML_INCLUDE_DIRS}
${FCL_INCLUDE_DIRS}
)
# ## dbastar
# add_executable(dbastar
# src/main_dbastar.cpp
# )
# target_link_libraries(dbastar
# motion_planning_common
# ${Boost_LIBRARIES}
# ${YAML_LIBRARIES}
# ompl
# ${FCL_LIBRARIES}
# )
# target_include_directories(dbastar PUBLIC
# ${YAML_INCLUDE_DIRS}
# ${FCL_INCLUDE_DIRS}
# )
## main_ompl_geometric
add_executable(main_ompl_geometric
src/main_ompl_geometric.cpp
)
target_link_libraries(main_ompl_geometric
motion_planning_common
${Boost_LIBRARIES}
${YAML_LIBRARIES}
ompl
${FCL_LIBRARIES}
)
target_include_directories(main_ompl_geometric PUBLIC
${YAML_INCLUDE_DIRS}
${FCL_INCLUDE_DIRS}
)
## db_cbs
add_executable(db_cbs
src/db_cbs.cpp
# src/robots.cpp
)
target_include_directories(db_cbs PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/dynoplan/include
)
#target_link_libraries(main_check_multirobot PRIVATE
# dynobench::dynobench
# idbastar::optimization
# motion_planning_common
# ${Boost_LIBRARIES}
# ${YAML_LIBRARIES}
# ompl
# ${FCL_LIBRARIES}
#)
target_link_libraries(db_cbs PRIVATE
idbastar::optimization
motion_planning_common
${Boost_LIBRARIES}
${YAML_LIBRARIES}
ompl
${FCL_LIBRARIES}
)
target_include_directories(main_ompl PUBLIC
${YAML_INCLUDE_DIRS}
${FCL_INCLUDE_DIRS}
)
# Python bindings
# add_subdirectory(deps/pybind11 EXCLUDE_FROM_ALL)
# pybind11_add_module(motionplanningutils
# src/python_bindings.cpp
# )
# target_include_directories(motionplanningutils
# PRIVATE ${CMAKE_BINARY_DIR}/deps/fcl/include
# PRIVATE ${CMAKE_SOURCE_DIR}/deps/fcl/include
# )
# target_link_libraries(motionplanningutils PRIVATE
# motion_planning_common
# ${Boost_LIBRARIES}
# ${YAML_LIBRARIES}
# ompl
# ${FCL_LIBRARIES}
# )