forked from RodolfoALopes/decomposition_library
-
Notifications
You must be signed in to change notification settings - Fork 0
/
DecompositionConfig.cmake.in
25 lines (21 loc) · 1.03 KB
/
DecompositionConfig.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
# Initialize CMakePackageConfigHelpers
# https://cmake.org/cmake/help/latest/module/CMakePackageConfigHelpers.html
@PACKAGE_INIT@
# Capture BUILD_SHARED_LIBS from configure time
set(DECOMPOSITION_BUILT_SHARED "@BUILD_SHARED_LIBS@")
if(NOT ${DECOMPOSITION_BUILT_SHARED})
# CMakeFindDependencyMacro wraps find_package for Config files
# find_dependency forwards QUIET and REQUIRED to find_package
# https://cmake.org/cmake/help/v3.18/module/CMakeFindDependencyMacro.html
include(CMakeFindDependencyMacro)
# Add this config dir to CMAKE_MODULE_PATH
list(APPEND CMAKE_MODULE_PATH ${DECOMPOSITION_CONFIG_INSTALL_DIR})
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}")
list(POP_BACK CMAKE_MODULE_PATH)
endif()
# Find any dependencies or any extra step here
# before including the targets file
include("${CMAKE_CURRENT_LIST_DIR}/DecompositionTargets.cmake")
# Called at the end if package has components to set Decomposition_FOUND
# https://cmake.org/cmake/help/v3.0/module/CMakePackageConfigHelpers.html
check_required_components(Decomposition)