Add DEPENDENCY_ADDED property (#50)

* add DEPENDENCY_ADDED property

* update examples

* Update README.md

* Update README.md

* Update CPM.cmake

* Update README.md
This commit is contained in:
Lars Melchior
2019-05-20 01:52:55 +02:00
committed by GitHub
parent 275a12f2d8
commit bf5e9ebafb
6 changed files with 36 additions and 20 deletions

View File

@@ -12,8 +12,10 @@ CPMAddPackage(
URL_HASH SHA256=69cc88207ce91347ea530b227ff0776db82dcb8de6704e1a3d74f4841bc651cf
)
add_library(nlohmann_json INTERFACE)
target_include_directories(nlohmann_json INTERFACE ${nlohmann_json_SOURCE_DIR})
if(nlohmann_json_ADDED)
add_library(nlohmann_json INTERFACE)
target_include_directories(nlohmann_json INTERFACE ${nlohmann_json_SOURCE_DIR})
endif()
# ---- Executable ----