We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4736992 commit 976357eCopy full SHA for 976357e
1 file changed
server/CMakeLists.txt
@@ -19,11 +19,15 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
19
find_package(nlohmann_json CONFIG QUIET)
20
if(NOT nlohmann_json_FOUND)
21
include(FetchContent)
22
- FetchContent_Declare(json
+ set(_dflash_json_fetch_args
23
URL https://github.com/nlohmann/json/releases/download/v3.11.3/json.tar.xz
24
- DOWNLOAD_EXTRACT_TIMESTAMP TRUE
25
URL_HASH SHA256=d6c65aca6b1ed68e7a182f4757257b107ae403032760ed6ef121c9d55e81757d
26
)
+ if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.24")
27
+ list(APPEND _dflash_json_fetch_args DOWNLOAD_EXTRACT_TIMESTAMP TRUE)
28
+ endif()
29
+ FetchContent_Declare(json ${_dflash_json_fetch_args})
30
+ unset(_dflash_json_fetch_args)
31
FetchContent_MakeAvailable(json)
32
endif()
33
0 commit comments