-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
57 lines (43 loc) · 1.79 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
cmake_minimum_required (VERSION 2.6)
project (FMM)
# Set a default build type for single-configuration
# CMake generators if no build type is set.
IF(NOT CMAKE_CONFIGURATION_TYPES AND NOT CMAKE_BUILD_TYPE)
SET(CMAKE_BUILD_TYPE Release)
ENDIF(NOT CMAKE_CONFIGURATION_TYPES AND NOT CMAKE_BUILD_TYPE)
# Select flags.
SET(CMAKE_CXX_FLAGS "-std=c++11")
SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O3 -g")
SET(CMAKE_CXX_FLAGS_RELEASE "-Ofast -fno-finite-math-only")
SET(CMAKE_CXX_FLAGS_DEBUG "-Wall -Wno-unused-local-typedefs -g")
# Find OpenCV
find_package(OpenCV REQUIRED)
#find_library(UUGearLib libUUGear.so)
# Self-made includes
include_directories (${FMM_SOURCE_DIR}/console)
include_directories (${FMM_SOURCE_DIR}/ndgridmap)
include_directories (${FMM_SOURCE_DIR}/fmm)
include_directories (${FMM_SOURCE_DIR}/fmm/fmdata)
include_directories (${FMM_SOURCE_DIR}/fm2)
include_directories (${FMM_SOURCE_DIR}/io)
include_directories (${FMM_SOURCE_DIR}/gradientdescent)
include_directories (~/repos/UUGear/RaspberryPi/src)
#include_directories (~/repos/UUGear/RaspberryPi/bin)
add_library (myUUGear /home/pi/repos/UUGear/RaspberryPi/src/UUGear.cpp)
add_library (myUUGearD /home/pi/repos/UUGear/RaspberryPi/src/UUGearDaemon.cpp)
# Third party internal includes
include_directories (${FMM_SOURCE_DIR}/thirdparty)
# External dependencies
include_directories (~/boost_1_55_0)
add_executable (fmm
console/console.cpp
ndgridmap/cell.cpp
fmm/fmdata/fmcell.cpp
~/repos/UUGear/RaspberryPi/src/serial.c
main.cpp
)
# Linking CImg dependencies.
target_link_libraries(fmm ${OpenCV_LIBS})
target_link_libraries (fmm X11 pthread rt myUUGear myUUGearD)
#target_link_libraries (fmm UUGearDaemon)
#target_link_libraries (fmm UUGearSerial)