nlohmann_json¶
Usage¶
since Hunter v0.19.52
hunter_add_package(nlohmann_json)
find_package(nlohmann_json CONFIG REQUIRED)
target_link_libraries(... nlohmann_json)
before Hunter v0.19.52
hunter_add_package(nlohmann-json)
find_package(nlohmann-json REQUIRED)
target_link_libraries(... nlohmann-json::nlohmann-json)
migration from V1.0.0 to V2.1.1¶
- replace all
nlohmann-jsonwithnlohmann_json - add
CONFIGtofind_package(nlohmann_json CONFIG REQUIRED) - shorten
target_link_libraries(), totarget_link_libraries(... nlohmann_json)nonlohmann_json::nlohmann_json - change
#include <json.hpp>to#include <nlohmann/json.hpp>