Am new to cpp but as per project requirements i need to consume rest api and parse the response. Am able to call api & capture the response but not able to parse it using JSONCPP library.
These are the steps i followed to parse json:
- Used this command to install libjsoncpp in ubuntu sudo apt-get install libjsoncpp-dev
- Downloaded json source files and copied json header files into project folder
- Compiling cpp using this command gcc -o test.out test.cpp -ljson
it is always giving
fatal error: json/json.h: No such file or directory
#include <json/json.h>
^
compilation terminated.
Didn't find any solution since 2 days. Tried this also. Can any one tell me where i am going wrong...