88.8. cjson-1.7.19
cJSON, a small ANSI C JSON parser (mosquitto links it)
1.7.19-1 · MIT · 0.3 SBU · 122.7 KiB, 17 files · 41_system, 258 of 1047 · ports/core/formats/cjson
Homepage: https://github.com/DaveGamble/cJSON
Why it is in KDOS. The comment above it in script/phases/41_system/packages.d/formats.txt:
cJSON is here for mosquitto's control plane rather than for its own sake.
Depends on: cmake.
Required by (4): librist, mosquitto, weechat, xastir.
Sources: cjson-1.7.19.tar.gz (347.9 KiB). Every step kpkg takes applies to this port.
Install: script/chroot/exec.sh bash -c 'source script/phases/41_system/phase.env && kpkg install cjson'
build.sh:
mkdir -p build && cd build
cmake .. -DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DBUILD_SHARED_AND_STATIC_LIBS=OFF -DENABLE_CJSON_TEST=OFF \
-DENABLE_CJSON_UTILS=ON
make
make DESTDIR=$PKG install
Libraries: libcjson.so, libcjson_utils.so.
Directories: /usr/include/cjson, /usr/lib/cmake/cJSON, /usr/share/licenses/cjson.