How to include a JSON library in a C++ program?


(Using windows 8, it's not UNIX-based.)

I'm pretty much a beginner in C++, I do have some knowledge of stuff like types of variables and a little bit of file structure.

I'm trying to go through with this tutorial: http://www.penguinprogrammer.co.uk/rpg-tutorial/introduction/

I'm having trouble in particular with the section titled JsonBox.
I've downloaded Cmake and the Jsonbox files but I can't seem to get them to work together, the tutorial is very loose about how to create build files and the like.

I was wondering if anybody could give a more in-depth explanation of how to generate files as outlined in the tutorial,

OR

if someone could notify me of another way to include the JsonBox library in a C++ program.




TL;DR

I need a C++ program to use the JsonBox library and I don't know how to make it.

Thanks in advance.
What happens when you run CMake? You should be getting some kind of errors if it isn't working when you try to run it on the JsonBox project.
The problem is more that none of the tutorials say what files I should set as the source code and binary.
If you are using the CMake GUI, you set the root of the project where the CMakeLists.txt file is located as the "where the source code is located".

The output directory is where the makefiles/IDE project/whatever you use to build the code will be output, and can pretty much go anywhere, though I use a separate directory called "codeblocks-build" or "nmake-build" or whatever to hold that output.

Then you use that output to actually build the project.

The particular project may have other settings/options in CMake, but the documentation for the project should explain those.
Screenshots:

http://imgur.com/a/pqnuO

Logs:

http://pastebin.com/pw414bGR


I think the issue is that I have visual studio selected and visual studio itself is not installed on my computer. I'll get back to you once I've installed VS community 2015.
The installation is a bit broken, I'm gonna take a bit longer.
If you don't have VS installed, what do you build with? CMake has many options for IDEs and makefiles, so you should select whichever one you are actually using. You don't need to get VS2015 for this to work.
in c++ all external method are not easily used ..these are very tough
Topic archived. No new replies allowed.