Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ArthurSonzogni/nlohmann_json_cmake_fetchcontent.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArthurSonzogni <sonzogniarthur@gmail.com>2020-04-29 16:45:05 +0300
committerArthurSonzogni <sonzogniarthur@gmail.com>2020-06-28 14:34:26 +0300
commit29433267e8e2dab0a63fe2098f34c31ef6140a5a (patch)
tree570a7b67f6825f02e66187e26063adee3e375e76 /CMakeLists.txt
Initial commit without calling 'update.py'
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt14
1 files changed, 14 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
new file mode 100644
index 0000000..5d6a605
--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,14 @@
+cmake_minimum_required(VERSION 3.1)
+project(nlohmann_json LANGUAGES CXX)
+
+add_library(nlohmann_json INTERFACE)
+add_library(nlohmann_json::nlohmann_json ALIAS nlohmann_json)
+target_include_directories(nlohmann_json
+ INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/include
+)
+
+if (${CMAKE_VERSION} VERSION_LESS "3.8.0")
+ target_compile_features(nlohmann_json INTERFACE cxx_range_for)
+else()
+ target_compile_features(nlohmann_json INTERFACE cxx_std_11)
+endif()