Skip to content
Snippets Groups Projects
Commit 040a0993 authored by Atkins, Charles Vernon's avatar Atkins, Charles Vernon
Browse files

Fixup interface libraries for JSON and XML libs.

parent 7ceaa52a
No related branches found
No related tags found
1 merge request!199Add cmake package configs
add_library(NLohmann::Json INTERFACE IMPORTED GLOBAL)
set_target_properties(NLohmann::Json PROPERTIES
INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_CURRENT_SOURCE_DIR}/json/src
)
add_subdirectory(json)
add_library(NLohmannJson INTERFACE)
target_include_directories(NLohmannJson INTERFACE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>
)
install(TARGETS NLohmannJson EXPORT adios2Exports)
# This is an extremely simple and tiny library. Rather than build it
# seperately we'll just create an interface library containing the sources and
# headers
add_library(pugixml INTERFACE)
target_sources(pugixml INTERFACE
${CMAKE_CURRENT_SOURCE_DIR}/pugixml/src/pugiconfig.hpp
${CMAKE_CURRENT_SOURCE_DIR}/pugixml/src/pugixml.hpp
${CMAKE_CURRENT_SOURCE_DIR}/pugixml/src/pugixml.cpp
)
target_include_directories(pugixml INTERFACE
${CMAKE_CURRENT_SOURCE_DIR}/pugixml/src
)
add_subdirectory(pugixml)
add_library(pugixml INTERFACE)
target_sources(pugixml INTERFACE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/pugiconfig.hpp>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/pugixml.hpp>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/pugixml.cpp>
)
target_include_directories(pugixml INTERFACE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>
)
install(TARGETS pugixml EXPORT adios2Exports)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment