-
Notifications
You must be signed in to change notification settings - Fork 4
/
config.cmake.in
30 lines (26 loc) · 1.19 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
26
27
28
29
30
@PACKAGE_INIT@
# Support both casing styles
list(APPEND JSONBINPACK_COMPONENTS ${JSONBinPack_FIND_COMPONENTS})
list(APPEND JSONBINPACK_COMPONENTS ${jsonbinpack_FIND_COMPONENTS})
if(NOT JSONBINPACK_COMPONENTS)
list(APPEND JSONBINPACK_COMPONENTS numeric)
list(APPEND JSONBINPACK_COMPONENTS runtime)
list(APPEND JSONBINPACK_COMPONENTS compiler)
endif()
include(CMakeFindDependencyMacro)
find_dependency(JSONToolkit COMPONENTS uri json jsonpointer jsonschema)
find_dependency(AlterSchema COMPONENTS engine linter)
foreach(component ${JSONBINPACK_COMPONENTS})
if(component STREQUAL "numeric")
include("${CMAKE_CURRENT_LIST_DIR}/sourcemeta_jsonbinpack_numeric.cmake")
elseif(component STREQUAL "runtime")
include("${CMAKE_CURRENT_LIST_DIR}/sourcemeta_jsonbinpack_numeric.cmake")
include("${CMAKE_CURRENT_LIST_DIR}/sourcemeta_jsonbinpack_runtime.cmake")
elseif(component STREQUAL "compiler")
include("${CMAKE_CURRENT_LIST_DIR}/sourcemeta_jsonbinpack_numeric.cmake")
include("${CMAKE_CURRENT_LIST_DIR}/sourcemeta_jsonbinpack_compiler.cmake")
else()
message(FATAL_ERROR "Unknown JSON BinPack component: ${component}")
endif()
endforeach()
check_required_components("@PROJECT_NAME@")