-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
38 lines (28 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
33
34
35
36
cmake_minimum_required(VERSION 3.22)
project(osm-transform
VERSION 0.1.0
DESCRIPTION "Package to customize OSM files")
# expose name & version
add_definitions( -DPROJECT_VERSION="${PROJECT_VERSION}" -DPROJECT_NAME="${PROJECT_NAME}")
# ignore BOOST deprecated headers
add_definitions("-DBOOST_ALLOW_DEPRECATED_HEADERS")
set(CMAKE_CXX_STANDARD 23)
set(CMAKE_CONFIGURATION_TYPES "Debug,Release" CACHE STRING "Configuration Types" FORCE)
option(BUILD_TESTING "Build the tests" ON)
# https://cmake.org/cmake/help/git-master/module/FindBoost.html
find_package(Boost REQUIRED regex program_options)
find_package(GDAL REQUIRED)
find_package(ZLIB REQUIRED)
find_package(CURL REQUIRED)
include_directories(${PROJECT_BINARY_DIR}/src)
set(SOURCE_FILES
location_area_service.cpp
location_elevation_service.cpp
rewrite_handler.cpp
)
add_subdirectory(src)
target_link_libraries(${PROJECT_NAME} PRIVATE z minizip bz2 expat GDAL::GDAL Boost::regex Boost::program_options CURL::libcurl)
if (BUILD_TESTING)
enable_testing()
add_subdirectory(test)
endif()