blob: 785548c211a931085c4075f6111c92ae1952986f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake }:
stdenv.mkDerivation rec {
pname = "json-c";
version = "0.16";
src = fetchFromGitHub {
owner = "json-c";
repo = "json-c";
rev = "json-c-0.16-20220414";
sha256 = "sha256-KbnUWLgpg6/1wvXhUoYswyqDcgiwEcvgaWCPjNcX20o=";
};
patches = [
# needed for emscripten, which uses LLVM 15+
(fetchpatch {
url = "https://github.com/json-c/json-c/commit/6eca65617aacd19f4928acd5766b8dd20eda0b34.patch";
sha256 = "sha256-fyugX+HgYlt/4AVtfNDaKS+blyUt8JYTNqkmhURb9dk=";
})
];
outputs = [ "out" "dev" ];
nativeBuildInputs = [ cmake ];
meta = with lib; {
description = "A JSON implementation in C";
longDescription = ''
JSON-C implements a reference counting object model that allows you to
easily construct JSON objects in C, output them as JSON formatted strings
and parse JSON formatted strings back into the C representation of JSON
objects.
'';
homepage = "https://github.com/json-c/json-c/wiki";
maintainers = with maintainers; [ lovek323 ];
platforms = platforms.unix;
license = licenses.mit;
};
}
|