-
Notifications
You must be signed in to change notification settings - Fork 5
/
futures-config.cmake.in
44 lines (36 loc) · 1.53 KB
/
futures-config.cmake.in
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
@PACKAGE_INIT@
# How futures installation was built
set(FUTURES_BUILT_SHARED "@BUILD_SHARED_LIBS@")
set(FUTURES_BUILT_CXX_COMPILER_ID "@CMAKE_CXX_COMPILER_ID@")
set(FUTURES_BUILT_CXX_COMPILER_VERSION "@CMAKE_CXX_COMPILER_VERSION@")
# Check if it matches the current toolchain
if (NOT CMAKE_CXX_COMPILER_ID STREQUAL FUTURES_BUILT_CXX_COMPILER_ID)
message(WARNING "This installation of futures was built with ${FUTURES_BUILT_CXX_COMPILER_ID}: "
"Current compiler is ${CMAKE_CXX_COMPILER_ID}.")
endif()
# Paths
set_and_check(FUTURES_INSTALL_DIR "@PACKAGE_CMAKE_INSTALL_LIBDIR@")
set_and_check(FUTURES_INCLUDE_DIR "@PACKAGE_INCLUDE_INSTALL_DIR@")
set_and_check(FUTURES_LIB_DIR "@PACKAGE_LIB_INSTALL_DIR@")
# Find dependencies
include(CMakeFindDependencyMacro)
list(APPEND CMAKE_MODULE_PATH ${FUTURES_CONFIG_INSTALL_DIR})
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}")
list(APPEND CMAKE_MODULE_PATH "${FUTURES_INCLUDE_DIR}")
list(APPEND CMAKE_MODULE_PATH "${FUTURES_INSTALL_DIR}")
set(FUTURES_INSTALL_HAD_ASIO @Asio_FOUND@)
set(FUTURES_INSTALL_FETCHED_ASIO @Asio_FETCHED@)
if (FUTURES_INSTALL_HAD_ASIO AND NOT FUTURES_INSTALL_FETCHED_ASIO)
find_dependency(Asio)
endif()
set(FUTURES_INSTALL_HAD_BOOST @Boost_FOUND@)
if (FUTURES_INSTALL_HAD_BOOST)
find_dependency(Boost)
endif()
set(FUTURES_INSTALL_HAD_THREADS @Threads_FOUND@)
if (FUTURES_INSTALL_HAD_THREADS)
find_dependency(Threads)
endif()
# Create imported targets
include("${CMAKE_CURRENT_LIST_DIR}/futures-targets.cmake")
check_required_components(futures)