]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/mp11/CMakeLists.txt
bump version to 18.2.2-pve1
[ceph.git] / ceph / src / boost / libs / mp11 / CMakeLists.txt
1 # Copyright 2018, 2019 Peter Dimov
2 # Distributed under the Boost Software License, Version 1.0.
3 # See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt
4
5 cmake_minimum_required(VERSION 3.5...3.16)
6
7 project(boost_mp11 VERSION 1.79.0 LANGUAGES CXX)
8
9 add_library(boost_mp11 INTERFACE)
10 add_library(Boost::mp11 ALIAS boost_mp11)
11
12 target_include_directories(boost_mp11 INTERFACE include)
13 target_compile_features(boost_mp11 INTERFACE cxx_alias_templates cxx_variadic_templates cxx_decltype)
14
15 if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
16
17 # Fetch support files
18
19 message(STATUS "Fetching BoostFetch.cmake")
20
21 file(DOWNLOAD
22 "https://raw.githubusercontent.com/boostorg/cmake/develop/include/BoostFetch.cmake"
23 "${CMAKE_BINARY_DIR}/fetch_and_include/BoostFetch.cmake"
24 )
25
26 include("${CMAKE_BINARY_DIR}/fetch_and_include/BoostFetch.cmake")
27
28 boost_fetch(boostorg/cmake TAG develop NO_ADD_SUBDIR)
29
30 FetchContent_GetProperties(boostorg_cmake)
31
32 list(APPEND CMAKE_MODULE_PATH ${boostorg_cmake_SOURCE_DIR}/include)
33
34 # Testing (off by default)
35
36 option(BUILD_TESTING "Build the tests." OFF)
37 include(CTest)
38
39 if(BUILD_TESTING)
40
41 set(BUILD_TESTING OFF) # hide cache variable
42
43 boost_fetch(boostorg/assert TAG develop EXCLUDE_FROM_ALL)
44 boost_fetch(boostorg/config TAG develop EXCLUDE_FROM_ALL)
45 boost_fetch(boostorg/core TAG develop EXCLUDE_FROM_ALL)
46 boost_fetch(boostorg/static_assert TAG develop EXCLUDE_FROM_ALL)
47 boost_fetch(boostorg/throw_exception TAG develop EXCLUDE_FROM_ALL)
48
49 unset(BUILD_TESTING)
50
51 endif()
52
53 # Do not use the default BoostInstall versioned layout on Windows when standalone
54 set(BOOST_INSTALL_LAYOUT "system" CACHE STRING "Installation layout (versioned, tagged, or system)")
55
56 include(BoostInstall)
57
58 boost_install(TARGETS boost_mp11 HEADER_DIRECTORY include/)
59
60 endif()
61
62 if(BUILD_TESTING)
63
64 add_subdirectory(test)
65
66 endif()