-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
35 changed files
with
511 additions
and
235 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
|
||
function(find_json_library) | ||
|
||
set(JSON_INCLUDE_DIR "" ) | ||
set(JSON_LIB_DIR "" ) | ||
set(JSON_LIB_CMAKE_DIR "" ) | ||
set(JSON_LIBRARY_PATH "" ) | ||
|
||
if(EXISTS ${DEPENDENCY_INSTALL_PATH}) | ||
set(JSON_LIB_CMAKE_DIR "${DEPENDENCY_INSTALL_PATH}/lib/cmake") | ||
set(JSON_INCLUDE_DIR "${DEPENDENCY_INSTALL_PATH}/include") | ||
set(JSON_LIB_DIR "${DEPENDENCY_INSTALL_PATH}/lib") | ||
endif() | ||
|
||
|
||
find_package(nlohmann_json CONFIG REQUIRED PATHS "${JSON_LIB_CMAKE_DIR}") | ||
|
||
# NOTE interfaces do not have a physical location associated with the library | ||
get_target_property(JSON_INCLUDE_PATH nlohmann_json::nlohmann_json INTERFACE_INCLUDE_DIRECTORIES ) | ||
|
||
set(DATAFED_JSON_INCLUDE_PATH "${JSON_INCLUDE_PATH}" PARENT_SCOPE) | ||
set(DATAFED_JSON_VERSION_ACTUAL "${nlohmann_json_VERSION}" PARENT_SCOPE) | ||
endfunction() | ||
|
||
find_json_library() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
|
||
function(find_json_schema_library) | ||
|
||
set(JSON_SCHEMA_INCLUDE_DIR "" ) | ||
set(JSON_SCHEMA_LIB_DIR "" ) | ||
set(JSON_SCHEMA_LIB_CMAKE_DIR "" ) | ||
set(JSON_SCHEMA_LIBRARY_PATH "" ) | ||
|
||
if(EXISTS ${DEPENDENCY_INSTALL_PATH}) | ||
set(JSON_SCHEMA_LIB_CMAKE_DIR "${DEPENDENCY_INSTALL_PATH}/lib/cmake") | ||
set(JSON_SCHEMA_INCLUDE_DIR "${DEPENDENCY_INSTALL_PATH}/include") | ||
set(JSON_SCHEMA_LIB_DIR "${DEPENDENCY_INSTALL_PATH}/lib") | ||
endif() | ||
|
||
find_package(nlohmann_json_schema_validator CONFIG REQUIRED VERSION "${JSON_SCHEMA_VALIDATOR_VERSION}" PATHS "${JSON_SCHEMA_LIB_CMAKE_DIR}") | ||
|
||
# NOTE interfaces do not have a physical location associated with the library | ||
get_target_property(JSON_SCHEMA_INCLUDE_PATH nlohmann_json_schema_validator INTERFACE_INCLUDE_DIRECTORIES) | ||
get_target_property(JSON_SCHEMA_LIBRARY_PATH nlohmann_json_schema_validator IMPORTED_LOCATION_NOCONFIG) | ||
|
||
set(DATAFED_JSON_SCHEMA_INCLUDE_PATH "${JSON_SCHEMA_INCLUDE_PATH}" PARENT_SCOPE) | ||
set(DATAFED_JSON_SCHEMA_LIBRARY_PATH "${JSON_SCHEMA_LIBRARY_PATH}" PARENT_SCOPE) | ||
set(DATAFED_JSON_SCHEMA_VERSION_ACTUAL "${nlohmann_json_schema_validator_VERSION}" PARENT_SCOPE) | ||
|
||
endfunction() | ||
|
||
find_json_schema_library() |
Oops, something went wrong.