-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
29 lines (22 loc) · 1.11 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
cmake_minimum_required(VERSION 3.3)
project (StatisticalDistributionsLib)
find_package(Boost REQUIRED)
# Require C++14 compilation
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
# Define library version
set(StatisticalDistributionsLib_VERSION_MAJOR 0 CACHE STRING "major version" FORCE)
set(StatisticalDistributionsLib_VERSION_MINOR 2 CACHE STRING "minor version" FORCE)
set(StatisticalDistributionsLib_VERSION ${StatisticalDistributionsLib_VERSION_MAJOR}.${StatisticalDistributionsLib_VERSION_MINOR} CACHE STRING "version" FORCE)
# Define install destinations
set(include_dest "include/StatisticalDistributionsLib-${StatisticalDistributionsLib_VERSION}")
set(main_lib_dest "lib/StatisticalDistributionsLib-${StatisticalDistributionsLib_VERSION}")
set(lib_dest ${main_lib_dest}/${CMAKE_BUILD_TYPE})
# Define options here
# Add subdirectories
include_directories(${Boost_INCLUDE_DIRS})
add_subdirectory(src)
# add_subdirectory(tests)
install(FILES StatisticalDistributionsLibConfig.cmake DESTINATION ${main_lib_dest})
install(EXPORT StatisticalDistributionsLib DESTINATION ${lib_dest})