-
Notifications
You must be signed in to change notification settings - Fork 4
/
CMakeLists.txt
32 lines (25 loc) · 1.06 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
cmake_minimum_required(VERSION 2.8.3)
project(dbow2_catkin)
find_package(catkin_simple REQUIRED)
catkin_simple()
include(ExternalProject)
file(MAKE_DIRECTORY ${CATKIN_DEVEL_PREFIX}/include)
ExternalProject_Add(dbow2_src
GIT_REPOSITORY https://github.com/dorian3d/DBoW2.git
GIT_TAG master
UPDATE_COMMAND ""
PATCH_COMMAND patch -p1 < ${CMAKE_CURRENT_LIST_DIR}/fix_fs_iter.patch
CONFIGURE_COMMAND cd ../dbow2_src && cmake -DCMAKE_BUILD_TYPE=Release
-DCMAKE_INSTALL_PREFIX:PATH=${CATKIN_DEVEL_PREFIX}
-DBUILD_Demo=Off .
BUILD_COMMAND cd ../dbow2_src && make
INSTALL_COMMAND cd ../dbow2_src && make install
)
install(DIRECTORY ${CATKIN_DEVEL_PREFIX}/include/DBoW2
DESTINATION ${CATKIN_GLOBAL_INCLUDE_DESTINATION}
FILES_MATCHING PATTERN "*.h")
install(DIRECTORY ${CATKIN_DEVEL_PREFIX}/lib/
DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
FILES_MATCHING PATTERN "libDBoW2*")
cs_export(INCLUDE_DIRS ${CATKIN_DEVEL_PREFIX}/include
LIBRARIES DBoW2)