-
Notifications
You must be signed in to change notification settings - Fork 26
/
CMakeLists.txt
83 lines (70 loc) · 1.98 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
cmake_minimum_required(VERSION 3.0.2)
project(sr_livo)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -O3")
find_package(catkin REQUIRED COMPONENTS
eigen_conversions
geometry_msgs
nav_msgs
pcl_conversions
pcl_ros
roscpp
rospy
sensor_msgs
std_msgs
tf
livox_ros_driver
cv_bridge
)
include(FetchContent)
FetchContent_Declare(
tessil
SOURCE_DIR ${PROJECT_SOURCE_DIR}/thirdLibrary/tessil-src)
if (NOT tessil_POPULATED)
set(BUILD_TESTING OFF)
FetchContent_Populate(tessil)
add_library(robin_map INTERFACE)
add_library(tsl::robin_map ALIAS robin_map)
target_include_directories(robin_map INTERFACE
"$<BUILD_INTERFACE:${tessil_SOURCE_DIR}/include>")
list(APPEND headers "${tessil_SOURCE_DIR}/include/tsl/robin_growth_policy.h"
"${tessil_SOURCE_DIR}/include/tsl/robin_hash.h"
"${tessil_SOURCE_DIR}/include/tsl/robin_map.h"
"${tessil_SOURCE_DIR}/include/tsl/robin_set.h")
target_sources(robin_map INTERFACE "$<BUILD_INTERFACE:${headers}>")
if (MSVC)
target_sources(robin_map INTERFACE
"$<BUILD_INTERFACE:${tessil_SOURCE_DIR}/tsl-robin-map.natvis>")
endif ()
endif ()
find_package(Eigen3 REQUIRED)
find_package(PCL 1.7 REQUIRED)
find_package(Ceres REQUIRED)
find_package(OpenCV REQUIRED)
catkin_package(
CATKIN_DEPENDS geometry_msgs nav_msgs roscpp rospy std_msgs
DEPENDS EIGEN3 PCL
INCLUDE_DIRS
)
include_directories(
${catkin_INCLUDE_DIRS}
${EIGEN3_INCLUDE_DIR}
${PCL_INCLUDE_DIRS}
${CERES_INCLUDE_DIRS}
${OpenCV_INCLUDE_DIRS}
robin_map
include
)
add_executable(livo_node
src/lioOptimization.cpp
src/imageProcessing.cpp
src/opticalFlowTracker.cpp
src/rgbMapTracker.cpp
src/lkpyramid.cpp
src/optimize.cpp
src/cloudMap.cpp
src/cloudProcessing.cpp
src/state.cpp
src/eskfEstimator.cpp
src/utility.cpp
src/parameters.cpp)
target_link_libraries(livo_node ${catkin_LIBRARIES} ${PCL_LIBRARIES} ${CERES_LIBRARIES} ${OpenCV_LIBRARIES} robin_map)