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
+18Lines changed: 18 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,7 @@ Ultralightweight JSON parser in ANSI C.
10
10
*[Copying the source](#copying-the-source)
11
11
*[CMake](#cmake)
12
12
*[Makefile](#makefile)
13
+
*[Meson](#meson)
13
14
*[Vcpkg](#Vcpkg)
14
15
*[Including cJSON](#including-cjson)
15
16
*[Data Structure](#data-structure)
@@ -145,6 +146,23 @@ make all
145
146
146
147
If you want, you can install the compiled library to your system using `make install`. By default it will install the headers in `/usr/local/include/cjson` and the libraries in `/usr/local/lib`. But you can change this behavior by setting the `PREFIX` and `DESTDIR` variables: `make PREFIX=/usr DESTDIR=temp install`. And uninstall them with: `make PREFIX=/usr DESTDIR=temp uninstall`.
147
148
149
+
#### Meson
150
+
151
+
To make cjson work in a project using meson, the libcjson dependency has to be included:
152
+
153
+
```meson
154
+
project('c-json-example', 'c')
155
+
156
+
cjson = dependency('libcjson')
157
+
158
+
example = executable(
159
+
'example',
160
+
'example.c',
161
+
dependencies: [cjson],
162
+
)
163
+
```
164
+
165
+
148
166
#### Vcpkg
149
167
150
168
You can download and install cJSON using the [vcpkg](https://github.com/Microsoft/vcpkg) dependency manager:
0 commit comments