forked from tpaviot/oce
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathProjectConfig.cmake.in
37 lines (34 loc) · 1.91 KB
/
ProjectConfig.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
# - Config file for the ${PROJECT_NAME} package
# It defines the following variables
# ${PROJECT_NAME}_INCLUDE_DIRS - include directory for ${PROJECT_NAME}
# ${PROJECT_NAME}_LIBRARIES - all libraries to link against (warning, may be slower than just specify the used libs)
# ${PROJECT_NAME}_ALL_FOUND - set to TRUE if all requested COMPONENTS are specified (see below), false otherwise
# ${PROJECT_NAME}_MISSING_TOOLKITS - when ${PROJECT_NAME}_ALL_FOUND is FALSE, contains a list of missing toolkits
#
# If COMPONENTS is specified in the find_package() commands, it contains
# a list of toolkit modules which are requested. For each component,
# ${PROJECT_NAME}_<toolkit>_FOUND is set to TRUE or FALSE.
# Warning: <toolkit> is case-sensitive, for instance TKernel.
# For convenience, ${PROJECT_NAME}_ALL_FOUND is set to TRUE if all
# toolkits are found, otherwise FALSE. In the latter case,
# ${PROJECT_NAME}_MISSING_TOOLKITS contains the list of missing toolkits.
# Tell the user project where to find our headers and libraries
GET_FILENAME_COMPONENT(SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
SET(@PROJECT_NAME@_INCLUDE_DIRS "${SELF_DIR}/@OCE_CMAKE_DATA_TO_INCLUDE_RELATIVE_DIR@")
SET(@PROJECT_NAME@_LIBRARIES "@OCE_LIBRARIES@")
INCLUDE("${SELF_DIR}/@[email protected]")
SET(@PROJECT_NAME@_ALL_FOUND true)
IF(@PROJECT_NAME@_FIND_COMPONENTS)
FOREACH(toolkit ${@PROJECT_NAME@_FIND_COMPONENTS})
IF(TARGET ${toolkit})
SET(@PROJECT_NAME@_${toolkit}_FOUND true)
ELSE(TARGET ${toolkit})
SET(@PROJECT_NAME@_ALL_FOUND false)
SET(@PROJECT_NAME@_${toolkit}_FOUND false)
SET(@PROJECT_NAME@_MISSING_TOOLKITS ${@PROJECT_NAME@_MISSING_TOOLKITS} ${toolkit})
IF(@PROJECT_NAME@_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "@PROJECT_NAME@ ${toolkit} not available.")
ENDIF(@PROJECT_NAME@_FIND_REQUIRED)
ENDIF(TARGET ${toolkit})
ENDFOREACH(toolkit ${@PROJECT_NAME@_FIND_COMPONENTS})
ENDIF(@PROJECT_NAME@_FIND_COMPONENTS)