mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-21 14:40:26 -06:00
FindBoost: Add new unit tests
This commit is contained in:
@@ -0,0 +1,140 @@
|
||||
# Copyright 2019 Peter Dimov
|
||||
# Distributed under the Boost Software License, Version 1.0.
|
||||
# (See accompanying file LICENSE_1_0.txt or copy at http://boost.org/LICENSE_1_0.txt)
|
||||
|
||||
# This CMake configuration file, installed as part of the Boost build
|
||||
# and installation procedure done by `b2 install`, provides support
|
||||
# for find_package(Boost).
|
||||
#
|
||||
# It's roughly, but not perfectly, compatible with the behavior
|
||||
# of find_package(Boost) as provided by FindBoost.cmake.
|
||||
#
|
||||
# A typical use might be
|
||||
#
|
||||
# find_package(Boost 1.70 REQUIRED COMPONENTS filesystem regex PATHS C:/Boost)
|
||||
#
|
||||
# On success, the above invocation would define the targets Boost::headers,
|
||||
# Boost::filesystem and Boost::regex. Boost::headers represents all
|
||||
# header-only libraries. An alias, Boost::boost, for Boost::headers is
|
||||
# provided for compatibility.
|
||||
#
|
||||
# Since Boost libraries can coexist in many variants - 32/64 bit,
|
||||
# static/dynamic runtime, debug/release, the following variables can be used
|
||||
# to control which variant is chosen:
|
||||
#
|
||||
# Boost_USE_DEBUG_LIBS: When OFF, disables debug libraries.
|
||||
# Boost_USE_RELEASE_LIBS: When OFF, disables release libraries.
|
||||
# Boost_USE_STATIC_LIBS: When ON, uses static Boost libraries; when OFF,
|
||||
# uses shared Boost libraries; when not set, the
|
||||
# default is to use shared when BUILD_SHARED_LIBS is
|
||||
# ON, static otherwise.
|
||||
# Boost_USE_STATIC_RUNTIME: When ON, uses Boost libraries linked against the
|
||||
# static runtime. The default is shared runtime.
|
||||
# Boost_USE_DEBUG_RUNTIME: When ON, uses Boost libraries linked against the
|
||||
# debug runtime. When OFF, against the release
|
||||
# runtime. The default is to use either.
|
||||
# Boost_COMPILER: The compiler that has been used to build Boost,
|
||||
# such as vc141, gcc7, clang37. The default is
|
||||
# determined from CMAKE_CXX_COMPILER_ID.
|
||||
|
||||
message(STATUS "Found Boost ${Boost_VERSION} at ${Boost_DIR}")
|
||||
|
||||
# Output requested configuration (f.ex. "REQUIRED COMPONENTS filesystem")
|
||||
|
||||
if(Boost_FIND_QUIETLY)
|
||||
set(_BOOST_CONFIG "${_BOOST_CONFIG} QUIET")
|
||||
endif()
|
||||
|
||||
if(Boost_FIND_REQUIRED)
|
||||
set(_BOOST_CONFIG "${_BOOST_CONFIG} REQUIRED")
|
||||
endif()
|
||||
|
||||
foreach(__boost_comp IN LISTS Boost_FIND_COMPONENTS)
|
||||
if(${Boost_FIND_REQUIRED_${__boost_comp}})
|
||||
list(APPEND _BOOST_COMPONENTS ${__boost_comp})
|
||||
else()
|
||||
list(APPEND _BOOST_OPTIONAL_COMPONENTS ${__boost_comp})
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
if(_BOOST_COMPONENTS)
|
||||
set(_BOOST_CONFIG "${_BOOST_CONFIG} COMPONENTS ${_BOOST_COMPONENTS}")
|
||||
endif()
|
||||
|
||||
if(_BOOST_OPTIONAL_COMPONENTS)
|
||||
set(_BOOST_CONFIG "${_BOOST_CONFIG} OPTIONAL_COMPONENTS ${_BOOST_OPTIONAL_COMPONENTS}")
|
||||
endif()
|
||||
|
||||
if(_BOOST_CONFIG)
|
||||
message(STATUS " Requested configuration:${_BOOST_CONFIG}")
|
||||
endif()
|
||||
|
||||
unset(_BOOST_CONFIG)
|
||||
unset(_BOOST_COMPONENTS)
|
||||
unset(_BOOST_OPTIONAL_COMPONENTS)
|
||||
|
||||
# find_dependency doesn't forward arguments until 3.9, so we have to roll our own
|
||||
|
||||
macro(boost_find_dependency dep req)
|
||||
|
||||
set(_BOOST_QUIET)
|
||||
if(Boost_FIND_QUIETLY)
|
||||
set(_BOOST_QUIET QUIET)
|
||||
endif()
|
||||
|
||||
set(_BOOST_REQUIRED)
|
||||
if(${req} AND Boost_FIND_REQUIRED)
|
||||
set(_BOOST_REQUIRED REQUIRED)
|
||||
endif()
|
||||
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS "BoostConfig: find_package(boost_${dep} ${Boost_VERSION} EXACT CONFIG ${_BOOST_REQUIRED} ${_BOOST_QUIET} HINTS ${_BOOST_CMAKEDIR})")
|
||||
endif()
|
||||
find_package(boost_${dep} ${Boost_VERSION} EXACT CONFIG ${_BOOST_REQUIRED} ${_BOOST_QUIET} HINTS ${_BOOST_CMAKEDIR})
|
||||
|
||||
string(TOUPPER ${dep} _BOOST_DEP)
|
||||
set(Boost_${_BOOST_DEP}_FOUND ${boost_${dep}_FOUND})
|
||||
|
||||
unset(_BOOST_REQUIRED)
|
||||
unset(_BOOST_QUIET)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
unset(_BOOST_DEP)
|
||||
|
||||
endmacro()
|
||||
|
||||
# Find boost_headers
|
||||
|
||||
boost_find_dependency(headers 1)
|
||||
|
||||
if(NOT boost_headers_FOUND)
|
||||
|
||||
set(Boost_FOUND 0)
|
||||
set(Boost_NOT_FOUND_MESSAGE "A required dependency, boost_headers, has not been found.")
|
||||
|
||||
return()
|
||||
|
||||
endif()
|
||||
|
||||
# Find components
|
||||
|
||||
foreach(__boost_comp IN LISTS Boost_FIND_COMPONENTS)
|
||||
|
||||
boost_find_dependency(${__boost_comp} ${Boost_FIND_REQUIRED_${__boost_comp}})
|
||||
|
||||
endforeach()
|
||||
|
||||
# Compatibility targets
|
||||
|
||||
if(NOT TARGET Boost::boost)
|
||||
|
||||
add_library(Boost::boost INTERFACE IMPORTED)
|
||||
set_property(TARGET Boost::boost APPEND PROPERTY INTERFACE_LINK_LIBRARIES Boost::headers)
|
||||
|
||||
# All Boost:: targets already disable autolink
|
||||
add_library(Boost::diagnostic_definitions INTERFACE IMPORTED)
|
||||
add_library(Boost::disable_autolinking INTERFACE IMPORTED)
|
||||
add_library(Boost::dynamic_linking INTERFACE IMPORTED)
|
||||
|
||||
endif()
|
||||
@@ -0,0 +1,12 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
set(PACKAGE_VERSION 1.70.0)
|
||||
|
||||
if(PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||
else()
|
||||
set(PACKAGE_VERSION_COMPATIBLE TRUE)
|
||||
if(PACKAGE_FIND_VERSION STREQUAL PACKAGE_VERSION)
|
||||
set(PACKAGE_VERSION_EXACT TRUE)
|
||||
endif()
|
||||
endif()
|
||||
@@ -0,0 +1 @@
|
||||
set(BOOST_DETECTED_TOOLSET "gcc7")
|
||||
@@ -0,0 +1,12 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
set(PACKAGE_VERSION 1.70.0)
|
||||
|
||||
if(PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||
else()
|
||||
set(PACKAGE_VERSION_COMPATIBLE TRUE)
|
||||
if(PACKAGE_FIND_VERSION STREQUAL PACKAGE_VERSION)
|
||||
set(PACKAGE_VERSION_EXACT TRUE)
|
||||
endif()
|
||||
endif()
|
||||
@@ -0,0 +1,98 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
if(TARGET Boost::chrono)
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS "Found boost_chrono ${boost_chrono_VERSION} at ${boost_chrono_DIR}")
|
||||
|
||||
# Compute the include and library directories relative to this file.
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
get_filename_component(_BOOST_INCLUDEDIR "${_BOOST_CMAKEDIR}/../../include/" ABSOLUTE)
|
||||
get_filename_component(_BOOST_LIBDIR "${_BOOST_CMAKEDIR}/../" ABSOLUTE)
|
||||
|
||||
# Create imported target Boost::chrono
|
||||
add_library(Boost::chrono UNKNOWN IMPORTED)
|
||||
|
||||
set_target_properties(Boost::chrono PROPERTIES
|
||||
INTERFACE_INCLUDE_DIRECTORIES "${_BOOST_INCLUDEDIR}"
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_ALL_NO_LIB"
|
||||
)
|
||||
|
||||
include(${CMAKE_CURRENT_LIST_DIR}/../BoostDetectToolset-1.70.0.cmake)
|
||||
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS "Scanning ${CMAKE_CURRENT_LIST_DIR}/libboost_chrono-variant*.cmake")
|
||||
endif()
|
||||
|
||||
file(GLOB __boost_variants "${CMAKE_CURRENT_LIST_DIR}/libboost_chrono-variant*.cmake")
|
||||
|
||||
macro(_BOOST_SKIPPED fname reason)
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS " ... skipped ${fname} (${reason})")
|
||||
endif()
|
||||
list(APPEND __boost_skipped "${fname} (${reason})")
|
||||
endmacro()
|
||||
|
||||
foreach(f IN LISTS __boost_variants)
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS " Including ${f}")
|
||||
endif()
|
||||
include(${f})
|
||||
endforeach()
|
||||
|
||||
unset(_BOOST_LIBDIR)
|
||||
unset(_BOOST_INCLUDEDIR)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
|
||||
get_target_property(__boost_configs Boost::chrono IMPORTED_CONFIGURATIONS)
|
||||
|
||||
if(__boost_variants AND NOT __boost_configs)
|
||||
message(STATUS "No suitable boost_chrono variant has been identified!")
|
||||
if(NOT Boost_DEBUG)
|
||||
foreach(s IN LISTS __boost_skipped)
|
||||
message(STATUS " ${s}")
|
||||
endforeach()
|
||||
endif()
|
||||
set(boost_chrono_FOUND 0)
|
||||
set(boost_chrono_NOT_FOUND_MESSAGE "No suitable build variant has been found.")
|
||||
unset(__boost_skipped)
|
||||
unset(__boost_configs)
|
||||
unset(__boost_variants)
|
||||
unset(_BOOST_CHRONO_DEPS)
|
||||
return()
|
||||
endif()
|
||||
|
||||
unset(__boost_skipped)
|
||||
unset(__boost_configs)
|
||||
unset(__boost_variants)
|
||||
|
||||
if(_BOOST_CHRONO_DEPS)
|
||||
list(REMOVE_DUPLICATES _BOOST_CHRONO_DEPS)
|
||||
message(STATUS "Adding boost_chrono dependencies: ${_BOOST_CHRONO_DEPS}")
|
||||
endif()
|
||||
|
||||
foreach(dep_boost_chrono IN LISTS _BOOST_CHRONO_DEPS)
|
||||
set(_BOOST_QUIET)
|
||||
if(boost_chrono_FIND_QUIETLY)
|
||||
set(_BOOST_QUIET QUIET)
|
||||
endif()
|
||||
set(_BOOST_REQUIRED)
|
||||
if(boost_chrono_FIND_REQUIRED)
|
||||
set(_BOOST_REQUIRED REQUIRED)
|
||||
endif()
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
find_package(boost_${dep_boost_chrono} 1.70.0 EXACT CONFIG ${_BOOST_REQUIRED} ${_BOOST_QUIET} HINTS ${_BOOST_CMAKEDIR})
|
||||
set_property(TARGET Boost::chrono APPEND PROPERTY INTERFACE_LINK_LIBRARIES Boost::${dep_boost_chrono})
|
||||
unset(_BOOST_QUIET)
|
||||
unset(_BOOST_REQUIRED)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
if(NOT boost_${dep_boost_chrono}_FOUND)
|
||||
set(boost_chrono_FOUND 0)
|
||||
set(boost_chrono_NOT_FOUND_MESSAGE "A required dependency, boost_${dep_boost_chrono}, has not been found.")
|
||||
unset(_BOOST_CHRONO_DEPS)
|
||||
return()
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
unset(_BOOST_CHRONO_DEPS)
|
||||
@@ -0,0 +1,62 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
# address-model=64
|
||||
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||
_BOOST_SKIPPED("libboost_chrono.so.1.70.0" "64 bit, need 32")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# layout=system
|
||||
|
||||
# toolset=gcc8
|
||||
|
||||
# link=shared
|
||||
|
||||
if(NOT "${Boost_USE_STATIC_LIBS}" STREQUAL "" AND Boost_USE_STATIC_LIBS)
|
||||
_BOOST_SKIPPED("libboost_chrono.so.1.70.0" "shared, Boost_USE_STATIC_LIBS=${Boost_USE_STATIC_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
if(NOT BUILD_SHARED_LIBS)
|
||||
_BOOST_SKIPPED("libboost_chrono.so.1.70.0" "shared, BUILD_SHARED_LIBS not ON, set Boost_USE_STATIC_LIBS=OFF to override")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-link=shared
|
||||
|
||||
if(Boost_USE_STATIC_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_chrono.so.1.70.0" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-debugging=off
|
||||
|
||||
if(Boost_USE_DEBUG_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_chrono.so.1.70.0" "release runtime, Boost_USE_DEBUG_RUNTIME=${Boost_USE_DEBUG_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# threading=multi
|
||||
|
||||
# variant=release
|
||||
|
||||
if(NOT "${Boost_USE_RELEASE_LIBS}" STREQUAL "" AND NOT Boost_USE_RELEASE_LIBS)
|
||||
_BOOST_SKIPPED("libboost_chrono.so.1.70.0" "release, Boost_USE_RELEASE_LIBS=${Boost_USE_RELEASE_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS " libboost_chrono.so.1.70.0")
|
||||
|
||||
# Target file name: libboost_chrono.so.1.70.0
|
||||
set_property(TARGET Boost::chrono APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
|
||||
set_target_properties(Boost::chrono PROPERTIES
|
||||
IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE CXX
|
||||
IMPORTED_LOCATION_RELEASE "${_BOOST_LIBDIR}/libboost_chrono.so.1.70.0"
|
||||
)
|
||||
|
||||
set_target_properties(Boost::chrono PROPERTIES
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_CHRONO_DYN_LINK"
|
||||
)
|
||||
|
||||
list(APPEND _BOOST_CHRONO_DEPS headers)
|
||||
@@ -0,0 +1,58 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
# address-model=64
|
||||
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||
_BOOST_SKIPPED("libboost_chrono.a" "64 bit, need 32")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# layout=system
|
||||
|
||||
# toolset=gcc8
|
||||
|
||||
# link=static
|
||||
|
||||
if(NOT "${Boost_USE_STATIC_LIBS}" STREQUAL "" AND NOT Boost_USE_STATIC_LIBS)
|
||||
_BOOST_SKIPPED("libboost_chrono.a" "static, Boost_USE_STATIC_LIBS=${Boost_USE_STATIC_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
_BOOST_SKIPPED("libboost_chrono.a" "static, BUILD_SHARED_LIBS=${BUILD_SHARED_LIBS}, set Boost_USE_STATIC_LIBS=ON to override")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-link=shared
|
||||
|
||||
if(Boost_USE_STATIC_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_chrono.a" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-debugging=off
|
||||
|
||||
if(Boost_USE_DEBUG_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_chrono.a" "release runtime, Boost_USE_DEBUG_RUNTIME=${Boost_USE_DEBUG_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# threading=multi
|
||||
|
||||
# variant=release
|
||||
|
||||
if(NOT "${Boost_USE_RELEASE_LIBS}" STREQUAL "" AND NOT Boost_USE_RELEASE_LIBS)
|
||||
_BOOST_SKIPPED("libboost_chrono.a" "release, Boost_USE_RELEASE_LIBS=${Boost_USE_RELEASE_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS " libboost_chrono.a")
|
||||
|
||||
# Target file name: libboost_chrono.a
|
||||
set_property(TARGET Boost::chrono APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
|
||||
set_target_properties(Boost::chrono PROPERTIES
|
||||
IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE CXX
|
||||
IMPORTED_LOCATION_RELEASE "${_BOOST_LIBDIR}/libboost_chrono.a"
|
||||
)
|
||||
|
||||
list(APPEND _BOOST_CHRONO_DEPS headers)
|
||||
@@ -0,0 +1,12 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
set(PACKAGE_VERSION 1.70.0)
|
||||
|
||||
if(PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||
else()
|
||||
set(PACKAGE_VERSION_COMPATIBLE TRUE)
|
||||
if(PACKAGE_FIND_VERSION STREQUAL PACKAGE_VERSION)
|
||||
set(PACKAGE_VERSION_EXACT TRUE)
|
||||
endif()
|
||||
endif()
|
||||
@@ -0,0 +1,20 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
if(TARGET Boost::headers)
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS "Found boost_headers ${boost_headers_VERSION} at ${boost_headers_DIR}")
|
||||
|
||||
# Compute the include and library directories relative to this file.
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
get_filename_component(_BOOST_INCLUDEDIR "${_BOOST_CMAKEDIR}/../../include/" ABSOLUTE)
|
||||
get_filename_component(_BOOST_LIBDIR "${_BOOST_CMAKEDIR}/../" ABSOLUTE)
|
||||
|
||||
# Create imported target Boost::headers
|
||||
add_library(Boost::headers INTERFACE IMPORTED)
|
||||
|
||||
set_target_properties(Boost::headers PROPERTIES
|
||||
INTERFACE_INCLUDE_DIRECTORIES "${_BOOST_INCLUDEDIR}"
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_ALL_NO_LIB"
|
||||
)
|
||||
@@ -0,0 +1,12 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
set(PACKAGE_VERSION 1.70.0)
|
||||
|
||||
if(PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||
else()
|
||||
set(PACKAGE_VERSION_COMPATIBLE TRUE)
|
||||
if(PACKAGE_FIND_VERSION STREQUAL PACKAGE_VERSION)
|
||||
set(PACKAGE_VERSION_EXACT TRUE)
|
||||
endif()
|
||||
endif()
|
||||
@@ -0,0 +1,98 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
if(TARGET Boost::system)
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS "Found boost_system ${boost_system_VERSION} at ${boost_system_DIR}")
|
||||
|
||||
# Compute the include and library directories relative to this file.
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
get_filename_component(_BOOST_INCLUDEDIR "${_BOOST_CMAKEDIR}/../../include/" ABSOLUTE)
|
||||
get_filename_component(_BOOST_LIBDIR "${_BOOST_CMAKEDIR}/../" ABSOLUTE)
|
||||
|
||||
# Create imported target Boost::system
|
||||
add_library(Boost::system UNKNOWN IMPORTED)
|
||||
|
||||
set_target_properties(Boost::system PROPERTIES
|
||||
INTERFACE_INCLUDE_DIRECTORIES "${_BOOST_INCLUDEDIR}"
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_ALL_NO_LIB"
|
||||
)
|
||||
|
||||
include(${CMAKE_CURRENT_LIST_DIR}/../BoostDetectToolset-1.70.0.cmake)
|
||||
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS "Scanning ${CMAKE_CURRENT_LIST_DIR}/libboost_system-variant*.cmake")
|
||||
endif()
|
||||
|
||||
file(GLOB __boost_variants "${CMAKE_CURRENT_LIST_DIR}/libboost_system-variant*.cmake")
|
||||
|
||||
macro(_BOOST_SKIPPED fname reason)
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS " ... skipped ${fname} (${reason})")
|
||||
endif()
|
||||
list(APPEND __boost_skipped "${fname} (${reason})")
|
||||
endmacro()
|
||||
|
||||
foreach(f IN LISTS __boost_variants)
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS " Including ${f}")
|
||||
endif()
|
||||
include(${f})
|
||||
endforeach()
|
||||
|
||||
unset(_BOOST_LIBDIR)
|
||||
unset(_BOOST_INCLUDEDIR)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
|
||||
get_target_property(__boost_configs Boost::system IMPORTED_CONFIGURATIONS)
|
||||
|
||||
if(__boost_variants AND NOT __boost_configs)
|
||||
message(STATUS "No suitable boost_system variant has been identified!")
|
||||
if(NOT Boost_DEBUG)
|
||||
foreach(s IN LISTS __boost_skipped)
|
||||
message(STATUS " ${s}")
|
||||
endforeach()
|
||||
endif()
|
||||
set(boost_system_FOUND 0)
|
||||
set(boost_system_NOT_FOUND_MESSAGE "No suitable build variant has been found.")
|
||||
unset(__boost_skipped)
|
||||
unset(__boost_configs)
|
||||
unset(__boost_variants)
|
||||
unset(_BOOST_SYSTEM_DEPS)
|
||||
return()
|
||||
endif()
|
||||
|
||||
unset(__boost_skipped)
|
||||
unset(__boost_configs)
|
||||
unset(__boost_variants)
|
||||
|
||||
if(_BOOST_SYSTEM_DEPS)
|
||||
list(REMOVE_DUPLICATES _BOOST_SYSTEM_DEPS)
|
||||
message(STATUS "Adding boost_system dependencies: ${_BOOST_SYSTEM_DEPS}")
|
||||
endif()
|
||||
|
||||
foreach(dep_boost_system IN LISTS _BOOST_SYSTEM_DEPS)
|
||||
set(_BOOST_QUIET)
|
||||
if(boost_system_FIND_QUIETLY)
|
||||
set(_BOOST_QUIET QUIET)
|
||||
endif()
|
||||
set(_BOOST_REQUIRED)
|
||||
if(boost_system_FIND_REQUIRED)
|
||||
set(_BOOST_REQUIRED REQUIRED)
|
||||
endif()
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
find_package(boost_${dep_boost_system} 1.70.0 EXACT CONFIG ${_BOOST_REQUIRED} ${_BOOST_QUIET} HINTS ${_BOOST_CMAKEDIR})
|
||||
set_property(TARGET Boost::system APPEND PROPERTY INTERFACE_LINK_LIBRARIES Boost::${dep_boost_system})
|
||||
unset(_BOOST_QUIET)
|
||||
unset(_BOOST_REQUIRED)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
if(NOT boost_${dep_boost_system}_FOUND)
|
||||
set(boost_system_FOUND 0)
|
||||
set(boost_system_NOT_FOUND_MESSAGE "A required dependency, boost_${dep_boost_system}, has not been found.")
|
||||
unset(_BOOST_SYSTEM_DEPS)
|
||||
return()
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
unset(_BOOST_SYSTEM_DEPS)
|
||||
@@ -0,0 +1,62 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
# address-model=64
|
||||
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||
_BOOST_SKIPPED("libboost_system.so.1.70.0" "64 bit, need 32")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# layout=system
|
||||
|
||||
# toolset=gcc8
|
||||
|
||||
# link=shared
|
||||
|
||||
if(NOT "${Boost_USE_STATIC_LIBS}" STREQUAL "" AND Boost_USE_STATIC_LIBS)
|
||||
_BOOST_SKIPPED("libboost_system.so.1.70.0" "shared, Boost_USE_STATIC_LIBS=${Boost_USE_STATIC_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
if(NOT BUILD_SHARED_LIBS)
|
||||
_BOOST_SKIPPED("libboost_system.so.1.70.0" "shared, BUILD_SHARED_LIBS not ON, set Boost_USE_STATIC_LIBS=OFF to override")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-link=shared
|
||||
|
||||
if(Boost_USE_STATIC_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_system.so.1.70.0" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-debugging=off
|
||||
|
||||
if(Boost_USE_DEBUG_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_system.so.1.70.0" "release runtime, Boost_USE_DEBUG_RUNTIME=${Boost_USE_DEBUG_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# threading=multi
|
||||
|
||||
# variant=release
|
||||
|
||||
if(NOT "${Boost_USE_RELEASE_LIBS}" STREQUAL "" AND NOT Boost_USE_RELEASE_LIBS)
|
||||
_BOOST_SKIPPED("libboost_system.so.1.70.0" "release, Boost_USE_RELEASE_LIBS=${Boost_USE_RELEASE_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS " libboost_system.so.1.70.0")
|
||||
|
||||
# Target file name: libboost_system.so.1.70.0
|
||||
set_property(TARGET Boost::system APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
|
||||
set_target_properties(Boost::system PROPERTIES
|
||||
IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE CXX
|
||||
IMPORTED_LOCATION_RELEASE "${_BOOST_LIBDIR}/libboost_system.so.1.70.0"
|
||||
)
|
||||
|
||||
set_target_properties(Boost::system PROPERTIES
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_SYSTEM_DYN_LINK"
|
||||
)
|
||||
|
||||
list(APPEND _BOOST_SYSTEM_DEPS headers)
|
||||
@@ -0,0 +1,58 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
# address-model=64
|
||||
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||
_BOOST_SKIPPED("libboost_system.a" "64 bit, need 32")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# layout=system
|
||||
|
||||
# toolset=gcc8
|
||||
|
||||
# link=static
|
||||
|
||||
if(NOT "${Boost_USE_STATIC_LIBS}" STREQUAL "" AND NOT Boost_USE_STATIC_LIBS)
|
||||
_BOOST_SKIPPED("libboost_system.a" "static, Boost_USE_STATIC_LIBS=${Boost_USE_STATIC_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
_BOOST_SKIPPED("libboost_system.a" "static, BUILD_SHARED_LIBS=${BUILD_SHARED_LIBS}, set Boost_USE_STATIC_LIBS=ON to override")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-link=shared
|
||||
|
||||
if(Boost_USE_STATIC_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_system.a" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-debugging=off
|
||||
|
||||
if(Boost_USE_DEBUG_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_system.a" "release runtime, Boost_USE_DEBUG_RUNTIME=${Boost_USE_DEBUG_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# threading=multi
|
||||
|
||||
# variant=release
|
||||
|
||||
if(NOT "${Boost_USE_RELEASE_LIBS}" STREQUAL "" AND NOT Boost_USE_RELEASE_LIBS)
|
||||
_BOOST_SKIPPED("libboost_system.a" "release, Boost_USE_RELEASE_LIBS=${Boost_USE_RELEASE_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS " libboost_system.a")
|
||||
|
||||
# Target file name: libboost_system.a
|
||||
set_property(TARGET Boost::system APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
|
||||
set_target_properties(Boost::system PROPERTIES
|
||||
IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE CXX
|
||||
IMPORTED_LOCATION_RELEASE "${_BOOST_LIBDIR}/libboost_system.a"
|
||||
)
|
||||
|
||||
list(APPEND _BOOST_SYSTEM_DEPS headers)
|
||||
@@ -0,0 +1,12 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
set(PACKAGE_VERSION 1.70.0)
|
||||
|
||||
if(PACKAGE_VERSION VERSION_LESS PACKAGE_FIND_VERSION)
|
||||
set(PACKAGE_VERSION_COMPATIBLE FALSE)
|
||||
else()
|
||||
set(PACKAGE_VERSION_COMPATIBLE TRUE)
|
||||
if(PACKAGE_FIND_VERSION STREQUAL PACKAGE_VERSION)
|
||||
set(PACKAGE_VERSION_EXACT TRUE)
|
||||
endif()
|
||||
endif()
|
||||
@@ -0,0 +1,98 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
if(TARGET Boost::timer)
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS "Found boost_timer ${boost_timer_VERSION} at ${boost_timer_DIR}")
|
||||
|
||||
# Compute the include and library directories relative to this file.
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
get_filename_component(_BOOST_INCLUDEDIR "${_BOOST_CMAKEDIR}/../../include/" ABSOLUTE)
|
||||
get_filename_component(_BOOST_LIBDIR "${_BOOST_CMAKEDIR}/../" ABSOLUTE)
|
||||
|
||||
# Create imported target Boost::timer
|
||||
add_library(Boost::timer UNKNOWN IMPORTED)
|
||||
|
||||
set_target_properties(Boost::timer PROPERTIES
|
||||
INTERFACE_INCLUDE_DIRECTORIES "${_BOOST_INCLUDEDIR}"
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_ALL_NO_LIB"
|
||||
)
|
||||
|
||||
include(${CMAKE_CURRENT_LIST_DIR}/../BoostDetectToolset-1.70.0.cmake)
|
||||
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS "Scanning ${CMAKE_CURRENT_LIST_DIR}/libboost_timer-variant*.cmake")
|
||||
endif()
|
||||
|
||||
file(GLOB __boost_variants "${CMAKE_CURRENT_LIST_DIR}/libboost_timer-variant*.cmake")
|
||||
|
||||
macro(_BOOST_SKIPPED fname reason)
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS " ... skipped ${fname} (${reason})")
|
||||
endif()
|
||||
list(APPEND __boost_skipped "${fname} (${reason})")
|
||||
endmacro()
|
||||
|
||||
foreach(f IN LISTS __boost_variants)
|
||||
if(Boost_DEBUG)
|
||||
message(STATUS " Including ${f}")
|
||||
endif()
|
||||
include(${f})
|
||||
endforeach()
|
||||
|
||||
unset(_BOOST_LIBDIR)
|
||||
unset(_BOOST_INCLUDEDIR)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
|
||||
get_target_property(__boost_configs Boost::timer IMPORTED_CONFIGURATIONS)
|
||||
|
||||
if(__boost_variants AND NOT __boost_configs)
|
||||
message(STATUS "No suitable boost_timer variant has been identified!")
|
||||
if(NOT Boost_DEBUG)
|
||||
foreach(s IN LISTS __boost_skipped)
|
||||
message(STATUS " ${s}")
|
||||
endforeach()
|
||||
endif()
|
||||
set(boost_timer_FOUND 0)
|
||||
set(boost_timer_NOT_FOUND_MESSAGE "No suitable build variant has been found.")
|
||||
unset(__boost_skipped)
|
||||
unset(__boost_configs)
|
||||
unset(__boost_variants)
|
||||
unset(_BOOST_TIMER_DEPS)
|
||||
return()
|
||||
endif()
|
||||
|
||||
unset(__boost_skipped)
|
||||
unset(__boost_configs)
|
||||
unset(__boost_variants)
|
||||
|
||||
if(_BOOST_TIMER_DEPS)
|
||||
list(REMOVE_DUPLICATES _BOOST_TIMER_DEPS)
|
||||
message(STATUS "Adding boost_timer dependencies: ${_BOOST_TIMER_DEPS}")
|
||||
endif()
|
||||
|
||||
foreach(dep_boost_timer IN LISTS _BOOST_TIMER_DEPS)
|
||||
set(_BOOST_QUIET)
|
||||
if(boost_timer_FIND_QUIETLY)
|
||||
set(_BOOST_QUIET QUIET)
|
||||
endif()
|
||||
set(_BOOST_REQUIRED)
|
||||
if(boost_timer_FIND_REQUIRED)
|
||||
set(_BOOST_REQUIRED REQUIRED)
|
||||
endif()
|
||||
get_filename_component(_BOOST_CMAKEDIR "${CMAKE_CURRENT_LIST_DIR}/../" ABSOLUTE)
|
||||
find_package(boost_${dep_boost_timer} 1.70.0 EXACT CONFIG ${_BOOST_REQUIRED} ${_BOOST_QUIET} HINTS ${_BOOST_CMAKEDIR})
|
||||
set_property(TARGET Boost::timer APPEND PROPERTY INTERFACE_LINK_LIBRARIES Boost::${dep_boost_timer})
|
||||
unset(_BOOST_QUIET)
|
||||
unset(_BOOST_REQUIRED)
|
||||
unset(_BOOST_CMAKEDIR)
|
||||
if(NOT boost_${dep_boost_timer}_FOUND)
|
||||
set(boost_timer_FOUND 0)
|
||||
set(boost_timer_NOT_FOUND_MESSAGE "A required dependency, boost_${dep_boost_timer}, has not been found.")
|
||||
unset(_BOOST_TIMER_DEPS)
|
||||
return()
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
unset(_BOOST_TIMER_DEPS)
|
||||
@@ -0,0 +1,62 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
# address-model=64
|
||||
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||
_BOOST_SKIPPED("libboost_timer.so.1.70.0" "64 bit, need 32")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# layout=system
|
||||
|
||||
# toolset=gcc8
|
||||
|
||||
# link=shared
|
||||
|
||||
if(NOT "${Boost_USE_STATIC_LIBS}" STREQUAL "" AND Boost_USE_STATIC_LIBS)
|
||||
_BOOST_SKIPPED("libboost_timer.so.1.70.0" "shared, Boost_USE_STATIC_LIBS=${Boost_USE_STATIC_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
if(NOT BUILD_SHARED_LIBS)
|
||||
_BOOST_SKIPPED("libboost_timer.so.1.70.0" "shared, BUILD_SHARED_LIBS not ON, set Boost_USE_STATIC_LIBS=OFF to override")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-link=shared
|
||||
|
||||
if(Boost_USE_STATIC_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_timer.so.1.70.0" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-debugging=off
|
||||
|
||||
if(Boost_USE_DEBUG_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_timer.so.1.70.0" "release runtime, Boost_USE_DEBUG_RUNTIME=${Boost_USE_DEBUG_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# threading=multi
|
||||
|
||||
# variant=release
|
||||
|
||||
if(NOT "${Boost_USE_RELEASE_LIBS}" STREQUAL "" AND NOT Boost_USE_RELEASE_LIBS)
|
||||
_BOOST_SKIPPED("libboost_timer.so.1.70.0" "release, Boost_USE_RELEASE_LIBS=${Boost_USE_RELEASE_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS " libboost_timer.so.1.70.0")
|
||||
|
||||
# Target file name: libboost_timer.so.1.70.0
|
||||
set_property(TARGET Boost::timer APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
|
||||
set_target_properties(Boost::timer PROPERTIES
|
||||
IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE CXX
|
||||
IMPORTED_LOCATION_RELEASE "${_BOOST_LIBDIR}/libboost_timer.so.1.70.0"
|
||||
)
|
||||
|
||||
set_target_properties(Boost::timer PROPERTIES
|
||||
INTERFACE_COMPILE_DEFINITIONS "BOOST_TIMER_DYN_LINK"
|
||||
)
|
||||
|
||||
list(APPEND _BOOST_TIMER_DEPS chrono headers)
|
||||
@@ -0,0 +1,58 @@
|
||||
# Generated by Boost 1.70.0
|
||||
|
||||
# address-model=64
|
||||
|
||||
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
|
||||
_BOOST_SKIPPED("libboost_timer.a" "64 bit, need 32")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# layout=system
|
||||
|
||||
# toolset=gcc8
|
||||
|
||||
# link=static
|
||||
|
||||
if(NOT "${Boost_USE_STATIC_LIBS}" STREQUAL "" AND NOT Boost_USE_STATIC_LIBS)
|
||||
_BOOST_SKIPPED("libboost_timer.a" "static, Boost_USE_STATIC_LIBS=${Boost_USE_STATIC_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
if(BUILD_SHARED_LIBS)
|
||||
_BOOST_SKIPPED("libboost_timer.a" "static, BUILD_SHARED_LIBS=${BUILD_SHARED_LIBS}, set Boost_USE_STATIC_LIBS=ON to override")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-link=shared
|
||||
|
||||
if(Boost_USE_STATIC_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_timer.a" "shared runtime, Boost_USE_STATIC_RUNTIME=${Boost_USE_STATIC_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# runtime-debugging=off
|
||||
|
||||
if(Boost_USE_DEBUG_RUNTIME)
|
||||
_BOOST_SKIPPED("libboost_timer.a" "release runtime, Boost_USE_DEBUG_RUNTIME=${Boost_USE_DEBUG_RUNTIME}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# threading=multi
|
||||
|
||||
# variant=release
|
||||
|
||||
if(NOT "${Boost_USE_RELEASE_LIBS}" STREQUAL "" AND NOT Boost_USE_RELEASE_LIBS)
|
||||
_BOOST_SKIPPED("libboost_timer.a" "release, Boost_USE_RELEASE_LIBS=${Boost_USE_RELEASE_LIBS}")
|
||||
return()
|
||||
endif()
|
||||
|
||||
message(STATUS " libboost_timer.a")
|
||||
|
||||
# Target file name: libboost_timer.a
|
||||
set_property(TARGET Boost::timer APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
|
||||
set_target_properties(Boost::timer PROPERTIES
|
||||
IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE CXX
|
||||
IMPORTED_LOCATION_RELEASE "${_BOOST_LIBDIR}/libboost_timer.a"
|
||||
)
|
||||
|
||||
list(APPEND _BOOST_TIMER_DEPS chrono headers)
|
||||
1
Tests/RunCMake/FindBoost/CommonNotFound-stderr.txt
Normal file
1
Tests/RunCMake/FindBoost/CommonNotFound-stderr.txt
Normal file
@@ -0,0 +1 @@
|
||||
.*
|
||||
1
Tests/RunCMake/FindBoost/CommonNotFound-stdout.txt
Normal file
1
Tests/RunCMake/FindBoost/CommonNotFound-stdout.txt
Normal file
@@ -0,0 +1 @@
|
||||
-- Could NOT find Boost
|
||||
2
Tests/RunCMake/FindBoost/CommonNotFound.cmake
Normal file
2
Tests/RunCMake/FindBoost/CommonNotFound.cmake
Normal file
@@ -0,0 +1,2 @@
|
||||
# Make sure to use the module mode signature here to not bypass FindBoost
|
||||
find_package(Boost 1.80 COMPONENTS timer foobar)
|
||||
13
Tests/RunCMake/FindBoost/CommonResults-stdout.txt
Normal file
13
Tests/RunCMake/FindBoost/CommonResults-stdout.txt
Normal file
@@ -0,0 +1,13 @@
|
||||
-- Found Boost: [^
|
||||
]* \(found suitable version "1\.70\.0", minimum required is "1\.60"\) found components: .*timer.*
|
||||
-- Boost_FOUND
|
||||
-- Boost_VERSION=(107000|1\.70\.0)
|
||||
-- Boost_VERSION_MAJOR=1
|
||||
-- Boost_VERSION_MINOR=70
|
||||
-- Boost_VERSION_PATCH=0
|
||||
-- Boost_VERSION_COUNT=3
|
||||
-- Boost::headers
|
||||
-- Boost::boost
|
||||
-- Boost::chrono
|
||||
-- Boost::timer
|
||||
(-- Boost::system)?
|
||||
25
Tests/RunCMake/FindBoost/CommonResults.cmake
Normal file
25
Tests/RunCMake/FindBoost/CommonResults.cmake
Normal file
@@ -0,0 +1,25 @@
|
||||
# Make sure to use the module mode signature here to not bypass FindBoost
|
||||
find_package(Boost 1.60 COMPONENTS timer MODULE)
|
||||
if(Boost_FOUND)
|
||||
message(STATUS "Boost_FOUND")
|
||||
endif()
|
||||
message(STATUS "Boost_VERSION=${Boost_VERSION}")
|
||||
message(STATUS "Boost_VERSION_MAJOR=${Boost_VERSION_MAJOR}")
|
||||
message(STATUS "Boost_VERSION_MINOR=${Boost_VERSION_MINOR}")
|
||||
message(STATUS "Boost_VERSION_PATCH=${Boost_VERSION_PATCH}")
|
||||
message(STATUS "Boost_VERSION_COUNT=${Boost_VERSION_COUNT}")
|
||||
if(TARGET Boost::headers)
|
||||
message(STATUS "Boost::headers")
|
||||
endif()
|
||||
if(TARGET Boost::boost)
|
||||
message(STATUS "Boost::boost")
|
||||
endif()
|
||||
if(TARGET Boost::chrono)
|
||||
message(STATUS "Boost::chrono")
|
||||
endif()
|
||||
if(TARGET Boost::timer)
|
||||
message(STATUS "Boost::timer")
|
||||
endif()
|
||||
if(TARGET Boost::system)
|
||||
message(STATUS "Boost::system")
|
||||
endif()
|
||||
2
Tests/RunCMake/FindBoost/ConfigMode.cmake
Normal file
2
Tests/RunCMake/FindBoost/ConfigMode.cmake
Normal file
@@ -0,0 +1,2 @@
|
||||
set(Boost_DIR ${CMAKE_CURRENT_SOURCE_DIR}/CMakePackageFixtures/Boost-1.70.0)
|
||||
include(${CMAKE_CURRENT_SOURCE_DIR}/CommonResults.cmake)
|
||||
2
Tests/RunCMake/FindBoost/ConfigModeNotFound.cmake
Normal file
2
Tests/RunCMake/FindBoost/ConfigModeNotFound.cmake
Normal file
@@ -0,0 +1,2 @@
|
||||
set(Boost_DIR ${CMAKE_CURRENT_SOURCE_DIR}/CMakePackageFixtures/Boost-1.70.0)
|
||||
include(${CMAKE_CURRENT_SOURCE_DIR}/CommonNotFound.cmake)
|
||||
@@ -0,0 +1,34 @@
|
||||
// Boost version.hpp configuration header file
|
||||
// ------------------------------//
|
||||
|
||||
// (C) Copyright John maddock 1999. Distributed under the Boost
|
||||
// Software License, Version 1.0. (See accompanying file
|
||||
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
|
||||
// See http://www.boost.org/libs/config for documentation
|
||||
|
||||
#ifndef BOOST_VERSION_HPP
|
||||
#define BOOST_VERSION_HPP
|
||||
|
||||
//
|
||||
// Caution: this is the only Boost header that is guaranteed
|
||||
// to change with every Boost release. Including this header
|
||||
// will cause a recompile every time a new Boost version is
|
||||
// used.
|
||||
//
|
||||
// BOOST_VERSION % 100 is the patch level
|
||||
// BOOST_VERSION / 100 % 1000 is the minor version
|
||||
// BOOST_VERSION / 100000 is the major version
|
||||
|
||||
#define BOOST_VERSION 107000
|
||||
|
||||
//
|
||||
// BOOST_LIB_VERSION must be defined to be the same as BOOST_VERSION
|
||||
// but as a *string* in the form "x_y[_z]" where x is the major version
|
||||
// number, y is the minor version number, and z is the patch level if not 0.
|
||||
// This is used by <config/auto_link.hpp> to select which library version to
|
||||
// link to.
|
||||
|
||||
#define BOOST_LIB_VERSION "1_70"
|
||||
|
||||
#endif
|
||||
4
Tests/RunCMake/FindBoost/ModuleMode.cmake
Normal file
4
Tests/RunCMake/FindBoost/ModuleMode.cmake
Normal file
@@ -0,0 +1,4 @@
|
||||
set(BOOST_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/MockInstalls/1.70.0)
|
||||
set(Boost_NO_BOOST_CMAKE ON)
|
||||
set(Boost_NO_SYSTEM_PATHS ON)
|
||||
include(${CMAKE_CURRENT_SOURCE_DIR}/CommonResults.cmake)
|
||||
4
Tests/RunCMake/FindBoost/ModuleModeNotFound.cmake
Normal file
4
Tests/RunCMake/FindBoost/ModuleModeNotFound.cmake
Normal file
@@ -0,0 +1,4 @@
|
||||
set(BOOST_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/MockInstalls/1.70.0)
|
||||
set(Boost_NO_BOOST_CMAKE ON)
|
||||
set(Boost_NO_SYSTEM_PATHS ON)
|
||||
include(${CMAKE_CURRENT_SOURCE_DIR}/CommonNotFound.cmake)
|
||||
@@ -3,3 +3,14 @@ unset(ENV{Boost_ROOT})
|
||||
|
||||
run_cmake(CMakePackage)
|
||||
run_cmake(NoCXX)
|
||||
|
||||
set(RunCMake-stdout-file CommonResults-stdout.txt)
|
||||
run_cmake(ConfigMode)
|
||||
run_cmake(ModuleMode)
|
||||
unset(RunCMake-stdout-file)
|
||||
set(RunCMake-stdout-file CommonNotFound-stdout.txt)
|
||||
set(RunCMake-stderr-file CommonNotFound-stderr.txt)
|
||||
run_cmake(ConfigModeNotFound)
|
||||
run_cmake(ModuleModeNotFound)
|
||||
unset(RunCMake-stdout-file)
|
||||
unset(RunCMake-stderr-file)
|
||||
|
||||
Reference in New Issue
Block a user