-
Notifications
You must be signed in to change notification settings - Fork 9
/
Config.cmake.in
25 lines (22 loc) · 1.16 KB
/
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
@PACKAGE_INIT@
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/Modules")
include(${CMAKE_CURRENT_LIST_DIR}/@CONFIG_TARGETS_FILE@)
set(_${CMAKE_FIND_PACKAGE_NAME}_supported_components @CONFIG_SUPPORTED_COMPONENTS@)
foreach(_comp ${${CMAKE_FIND_PACKAGE_NAME}_FIND_COMPONENTS})
if(NOT _comp IN_LIST _${CMAKE_FIND_PACKAGE_NAME}_supported_components)
set(${CMAKE_FIND_PACKAGE_NAME}_FOUND False)
set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE "Unsupported component: ${_comp}")
elseif(EXISTS "${CMAKE_CURRENT_LIST_DIR}/${CMAKE_FIND_PACKAGE_NAME}${_comp}Targets.cmake")
set(${CMAKE_FIND_PACKAGE_NAME}_${_comp}_FOUND True)@CONFIG_FIND_COMPONENT_DEPENDENCIES@
if(${CMAKE_FIND_PACKAGE_NAME}_${_comp}_FOUND)
include("${CMAKE_CURRENT_LIST_DIR}/${CMAKE_FIND_PACKAGE_NAME}${_comp}Targets.cmake")
endif()
else()
set(${CMAKE_FIND_PACKAGE_NAME}_${_comp}_FOUND False)
if(${CMAKE_FIND_PACKAGE_NAME}_FIND_REQUIRED_${_comp})
set(${CMAKE_FIND_PACKAGE_NAME}_FOUND False)
set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE "Component not found: ${_comp}")
endif()
endif()
endforeach()
unset(_${CMAKE_FIND_PACKAGE_NAME}_supported_components)