I'm fairly new to C/C++ programming, I am trying to use the nlohmann-json library but having a lot of trouble trying to compile it with my program. According to the instruction, all I need is the json.hpp
in single_include/nlohmann
. I have tried to copy that to my root directory and include all of the directives that is required which are
#include <nlohmann/json.hpp>
// for convenience
using json = nlohmann::json;
in my program. However, when I try to compile it with clang++ example.cpp -o example
, it gives me this error:
'nlohmann/json.hpp' file not found with <angled> include; use "quotes" instead
#include <nlohmann/json.hpp>
Can anyone provide me some guidance to how I could solve this problem?
Please login or Register to submit your answer