You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+13-113
Original file line number
Diff line number
Diff line change
@@ -71,117 +71,23 @@ correct order and defining the macro `JSON_IS_AMALGAMATION` to prevent inclusion
71
71
72
72
## Contributing to JsonCpp
73
73
74
-
### Building and testing with Conan
74
+
### Building and testing with Meson/Ninja
75
+
Thanks to David Seifert (@SoapGentoo), we (the maintainers) now use [meson](http://mesonbuild.com/) and [ninja](https://ninja-build.org/) to build for debugging, as well as for continuous integration (see [`travis.sh`](travis.sh) ). Other systems may work, but minor things like version strings might break.
75
76
76
-
[Conan](https://www.conan.io/#/) is an open source package manager intended for C/C++ projects.
77
-
It is cross platform and build system agnostic.
77
+
First, install both meson (which requires Python3) and ninja.
78
78
79
-
Conan requires Python for running, and can be installed using pip:
Detailed instructions can be found on [conan docs](http://docs.conan.io/en/latest/).
84
-
85
-
For build jsoncpp with conan, you need to create a [conanfile.txt](http://docs.conan.io/en/latest/reference/conanfile_txt.html) or a [conanfile.py](http://docs.conan.io/en/latest/reference/conanfile.html). The first is simpler, but the second is more flexible.
86
-
87
-
This is a sample conanfile.txt:
88
-
89
-
```
90
-
[requires]
91
-
jsoncpp/1.8.0@theirix/ci
92
-
93
-
[generators]
94
-
cmake
95
-
```
96
-
97
-
**Note**: cmake is not required, you can use other [integrations](http://docs.conan.io/en/latest/integrations.html). Or you can set the appropriate environment variables, using [virtualenv generators](http://docs.conan.io/en/latest/mastering/virtualenv.html).
98
-
99
-
Then run the following command from the conanfile directory:
100
-
101
-
conan install --build missing
102
-
103
-
This will try to download the appropriate package for your settings (OS, compiler, architecture) from the [recipe packages](https://www.conan.io/source/jsoncpp/1.8.0/theirix/ci). If it is not found, the package will be built.
104
-
105
-
**Note**: you do not need to install cmake to build jsoncpp using conan, because the recipe will download it automatically.
106
-
107
-
If you need, you can customize the jsoncpp recipe. Just clone/fork [it from github](https://github.com/theirix/conan-jsoncpp/).
108
-
109
-
See [integrations instructions](http://docs.conan.io/en/latest/integrations.html) for how to use your build system with conan.
110
-
111
-
### Building and testing with CMake
112
-
113
-
[CMake][] is a C++ Makefiles/Solution generator. It is usually available on most Linux system as package. On Ubuntu:
114
-
115
-
sudo apt-get install cmake
116
-
117
-
[CMake]: http://www.cmake.org
118
-
119
-
Note that Python is also required to run the JSON reader/writer tests. If
120
-
missing, the build will skip running those tests.
121
-
122
-
When running CMake, a few parameters are required:
123
-
124
-
* A build directory where the makefiles/solution are generated. It is also used
125
-
to store objects, libraries and executables files.
126
-
* The generator to use: makefiles or Visual Studio solution? What version or
127
-
Visual Studio, 32 or 64 bits solution?
128
-
129
-
Steps for generating solution/makefiles using `cmake-gui`:
130
-
131
-
* Make "source code" point to the source directory.
132
-
* Make "where to build the binary" point to the directory to use for the build.
133
-
* Click on the "Grouped" check box.
134
-
* Review JsonCpp build options (tick `BUILD_SHARED_LIBS` to build as a
135
-
dynamic library).
136
-
* Click the configure button at the bottom, then the generate button.
137
-
* The generated solution/makefiles can be found in the binary directory.
138
-
139
-
Alternatively, from the command-line on Unix in the source directory:
0 commit comments