mirror of
https://github.com/boostorg/safe_numerics.git
synced 2026-07-21 13:33:46 +00:00
Add a Boost-friendly subproject case to CMakeLists
This commit is contained in:
@@ -1,3 +1,33 @@
|
||||
if(NOT CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
|
||||
|
||||
# Generated by `boostdep --cmake safe_numerics`
|
||||
# Copyright 2020, 2021 Peter Dimov
|
||||
# Distributed under the Boost Software License, Version 1.0.
|
||||
# https://www.boost.org/LICENSE_1_0.txt
|
||||
|
||||
cmake_minimum_required(VERSION 3.8...3.20)
|
||||
|
||||
project(boost_safe_numerics VERSION "${BOOST_SUPERPROJECT_VERSION}" LANGUAGES CXX)
|
||||
|
||||
add_library(boost_safe_numerics INTERFACE)
|
||||
add_library(Boost::safe_numerics ALIAS boost_safe_numerics)
|
||||
|
||||
target_include_directories(boost_safe_numerics INTERFACE include)
|
||||
|
||||
target_link_libraries(boost_safe_numerics
|
||||
INTERFACE
|
||||
Boost::concept_check
|
||||
Boost::config
|
||||
Boost::core
|
||||
Boost::integer
|
||||
Boost::logic
|
||||
Boost::mp11
|
||||
)
|
||||
|
||||
target_compile_features(boost_safe_numerics INTERFACE cxx_std_14)
|
||||
|
||||
else()
|
||||
|
||||
# CMake build control file for safe numerics Library Examples
|
||||
|
||||
cmake_minimum_required(VERSION 3.8.6)
|
||||
@@ -129,3 +159,4 @@ add_subdirectory("include/boost/safe_numerics")
|
||||
add_subdirectory("example")
|
||||
add_subdirectory("test")
|
||||
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user