Change: make nlohmann a mandatory library to build OpenTTD (#11235)

This commit is contained in:
Patric Stout
2023-08-28 19:04:36 +02:00
committed by GitHub
parent 13b76b0243
commit a3d631ffed
8 changed files with 9 additions and 34 deletions

View File

@@ -119,12 +119,13 @@ endif()
set(CMAKE_THREAD_PREFER_PTHREAD YES)
# Make sure we have Threads available.
find_package(Threads REQUIRED)
# nlohmann is used for all our JSON needs.
find_package(nlohmann_json REQUIRED)
find_package(ZLIB)
find_package(LibLZMA)
find_package(LZO)
find_package(PNG)
find_package(nlohmann_json)
if(WIN32 OR EMSCRIPTEN)
# Windows uses WinHttp for HTTP requests.
@@ -309,7 +310,7 @@ link_package(PNG TARGET PNG::PNG ENCOURAGED)
link_package(ZLIB TARGET ZLIB::ZLIB ENCOURAGED)
link_package(LIBLZMA TARGET LibLZMA::LibLZMA ENCOURAGED)
link_package(LZO)
link_package(nlohmann_json ENCOURAGED)
link_package(nlohmann_json)
if(NOT WIN32 AND NOT EMSCRIPTEN)
link_package(CURL ENCOURAGED)