-
Notifications
You must be signed in to change notification settings - Fork 5
/
CMakeLists.txt
57 lines (50 loc) · 2.34 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.8.8 FATAL_ERROR)
cmake_policy(VERSION 2.8.8)
project(maps-express)
set(CMAKE_C_OUTPUT_EXTENSION_REPLACE 1)
set(CMAKE_CXX_OUTPUT_EXTENSION_REPLACE 1)
file(GLOB_RECURSE maps-express_src
${PROJECT_SOURCE_DIR}/src/*.h
${PROJECT_SOURCE_DIR}/src/*.cpp)
add_executable(maps-express ${maps-express_src})
list(APPEND maps-express__include_dirs
"${CMAKE_SOURCE_DIR}/mapnik-vector-tile/src"
"${CMAKE_SOURCE_DIR}/src/include"
"${CMAKE_SOURCE_DIR}/mapnik-vector-tile/deps/protozero/include"
"${CMAKE_SOURCE_DIR}/mapnik-vector-tile/build/Release/obj/gen/"
"${CMAKE_SOURCE_DIR}/mapnik-vector-tile/deps/clipper/cpp"
"/usr/include/mapnik/agg")
set_property(TARGET maps-express APPEND PROPERTY INCLUDE_DIRECTORIES ${maps-express__include_dirs})
set_target_properties(maps-express PROPERTIES COMPILE_DEFINITIONS
"CLIPPER_INTPOINT_IMPL=mapnik::geometry::point<cInt>;CLIPPER_PATH_IMPL=mapnik::geometry::line_string<cInt>;\
CLIPPER_PATHS_IMPL=mapnik::geometry::multi_line_string<cInt>;CLIPPER_IMPL_INCLUDE=<mapnik/geometry.hpp>;\
MAPNIK_PLUGINDIR=\"/usr/lib/mapnik/3.0/input\";")
set_target_properties(maps-express PROPERTIES COMPILE_FLAGS "-std=c++14 -DMAPNIK_VECTOR_TILE_LIBRARY \
-DMAPNIK_MEMORY_MAPPED_FILE -DMAPNIK_HAS_DLCFN -DBIGINT -DBOOST_REGEX_HAS_ICU -DHAVE_JPEG -DMAPNIK_USE_PROJ4 \
-DHAVE_PNG -DHAVE_WEBP -DHAVE_TIFF -DLINUX -DMAPNIK_THREADSAFE -DBOOST_SPIRIT_NO_PREDEFINED_TERMINALS=1 \
-DBOOST_PHOENIX_NO_PREDEFINED_TERMINALS=1 -DBOOST_SPIRIT_USE_PHOENIX_V3=1 -DHAVE_CAIRO -DGRID_RENDERER \
-fvisibility=hidden -fvisibility-inlines-hidden -Wall -pthread -ftemplate-depth-300 -Wsign-compare -Wshadow \
-Werror")
target_link_libraries(maps-express
${CMAKE_SOURCE_DIR}/mapnik-vector-tile/build/Release/obj.target/gyp/libmapnik_vector_tile_impl.a
${CMAKE_SOURCE_DIR}/mapnik-vector-tile/build/Release/obj.target/gyp/libvector_tile.a
-licuuc
-lz
-lmapnik
-pthread
-lfolly
-lglog
-lgflags
-lcassandra
-lproxygenlib
-lproxygenhttpserver
-lcrypto
-ljsoncpp
-lboost_system
-lboost_filesystem
-lcouchbase
-lmapbox2mapnik
)
install(TARGETS maps-express DESTINATION /opt/sputnik/maps/maps-express/)
install(DIRECTORY DESTINATION /opt/sputnik/maps/maps-express/logs
DIRECTORY_PERMISSIONS WORLD_READ WORLD_WRITE)