mirror of
https://github.com/boostorg/heap.git
synced 2026-01-19 16:22:16 +00:00
`cxx_std_14` is only available since CMake 3.8 The `CXX_STANDARD_REQUIRED` property is a boolean, i.e. ON or OFF not a numeric value. The feature is enough to require the standard already
63 lines
1.9 KiB
CMake
63 lines
1.9 KiB
CMake
# Generated by `boostdep --cmake heap`
|
|
# Copyright 2020 Peter Dimov
|
|
# Copyright 2025 Alexander Grund
|
|
# Distributed under the Boost Software License, Version 1.0.
|
|
# https://www.boost.org/LICENSE_1_0.txt
|
|
|
|
cmake_minimum_required(VERSION 3.8...3.16)
|
|
|
|
project(boost_heap VERSION "${BOOST_SUPERPROJECT_VERSION}" LANGUAGES CXX)
|
|
|
|
option(BOOST_HEAP_BUILD_TESTS "Build boost::heap tests" OFF)
|
|
option(BOOST_HEAP_USE_FILE_SET "Use FILE_SET for boost::heap" OFF)
|
|
|
|
if (NOT DEFINED CMAKE_CXX_STANDARD)
|
|
set(CMAKE_CXX_STANDARD 14)
|
|
endif()
|
|
|
|
add_library(boost_heap INTERFACE)
|
|
add_library(Boost::heap ALIAS boost_heap)
|
|
|
|
target_include_directories(boost_heap INTERFACE include)
|
|
target_compile_features(boost_heap INTERFACE cxx_std_14)
|
|
|
|
target_link_libraries(boost_heap
|
|
INTERFACE
|
|
Boost::assert
|
|
Boost::concept_check
|
|
Boost::config
|
|
Boost::core
|
|
Boost::intrusive
|
|
Boost::iterator
|
|
Boost::parameter
|
|
Boost::static_assert
|
|
Boost::throw_exception
|
|
)
|
|
|
|
if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.23 AND BOOST_HEAP_USE_FILE_SET)
|
|
set(Headers
|
|
include/boost/heap/detail/ilog2.hpp
|
|
include/boost/heap/detail/heap_comparison.hpp
|
|
include/boost/heap/detail/mutable_heap.hpp
|
|
include/boost/heap/detail/ordered_adaptor_iterator.hpp
|
|
include/boost/heap/detail/stable_heap.hpp
|
|
include/boost/heap/detail/tree_iterator.hpp
|
|
include/boost/heap/detail/heap_node.hpp
|
|
include/boost/heap/heap_concepts.hpp
|
|
include/boost/heap/heap_merge.hpp
|
|
include/boost/heap/policies.hpp
|
|
include/boost/heap/binomial_heap.hpp
|
|
include/boost/heap/d_ary_heap.hpp
|
|
include/boost/heap/fibonacci_heap.hpp
|
|
include/boost/heap/pairing_heap.hpp
|
|
include/boost/heap/priority_queue.hpp
|
|
include/boost/heap/skew_heap.hpp
|
|
)
|
|
|
|
target_sources(boost_heap PUBLIC FILE_SET HEADERS FILES ${Headers} )
|
|
endif()
|
|
|
|
if( BOOST_HEAP_BUILD_TESTS OR BUILD_TESTING )
|
|
add_subdirectory(test)
|
|
endif()
|