Skip to content

Commit e9400b0

Browse files
committed
json-c: update to 0.17
Signed-off-by: Rosen Penev <[email protected]>
1 parent 3447894 commit e9400b0

File tree

3 files changed

+19
-17
lines changed

3 files changed

+19
-17
lines changed

releases.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1109,6 +1109,7 @@
11091109
},
11101110
"json-c": {
11111111
"versions": [
1112+
"0.17-1",
11121113
"0.16-4",
11131114
"0.16-3",
11141115
"0.16-2",

subprojects/json-c.wrap

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
[wrap-file]
2-
directory = json-c-0.16
3-
source_url = https://s3.amazonaws.com/json-c_releases/releases/json-c-0.16.tar.gz
4-
source_filename = json-c-0.16.tar.gz
5-
source_hash = 8e45ac8f96ec7791eaf3bb7ee50e9c2100bbbc87b8d0f1d030c5ba8a0288d96b
2+
directory = json-c-0.17
3+
source_url = https://s3.amazonaws.com/json-c_releases/releases/json-c-0.17.tar.gz
4+
source_filename = json-c-0.17.tar.gz
5+
source_hash = 7550914d58fb63b2c3546f3ccfbe11f1c094147bd31a69dcd23714d7956159e6
66
patch_directory = json-c
77

88
[provide]

subprojects/packagefiles/json-c/meson.build

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
project('json-c', 'c',
2-
version: '0.16',
2+
version: '0.17',
33
license: 'MIT',
44
meson_version: '>=0.49',
55
default_options: ['c_std=gnu99'],
@@ -8,17 +8,16 @@ project('json-c', 'c',
88
cc = meson.get_compiler('c')
99

1010
if cc.get_argument_syntax() == 'msvc'
11-
add_project_arguments('-D_CRT_SECURE_NO_WARNINGS', cc.get_supported_arguments('-Wno-deprecated-declarations'), language: 'c')
11+
add_project_arguments('-D_CRT_SECURE_NO_WARNINGS', '-DWIN32=_WIN32', language: 'c')
12+
else
13+
add_project_arguments('-D_GNU_SOURCE', language: 'c')
1214
endif
1315

1416
if get_option('default_library') != 'static'
1517
add_project_arguments('-DJSON_C_DLL', language: 'c')
1618
endif
1719

18-
add_project_arguments('-D_GNU_SOURCE', language: 'c')
19-
if cc.has_argument('-Wno-unused')
20-
add_project_arguments('-Wno-unused', language: 'c')
21-
endif
20+
add_project_arguments(cc.get_supported_arguments('-Wno-deprecated-declarations'), language: 'c')
2221

2322
threads = dependency('threads', required: false)
2423
math = cc.find_library('m', required: false)
@@ -28,7 +27,7 @@ inc = include_directories('config')
2827

2928
json_config = configuration_data()
3029
if conf.has('HAVE_INTTYPES_H')
31-
json_config.set10('JSON_C_HAVE_INTTYPES_H', true)
30+
json_config.set('JSON_C_HAVE_INTTYPES_H', 1)
3231
endif
3332
json_config_h = configure_file(
3433
configuration: json_config,
@@ -37,6 +36,7 @@ json_config_h = configure_file(
3736

3837
jconf = configuration_data()
3938
jconf.set('JSON_H_JSON_POINTER', '#include "json_pointer.h"')
39+
jconf.set('JSON_H_JSON_PATCH', '#include "json_patch.h"')
4040

4141
json_h = configure_file(
4242
input: 'json.h.cmakein',
@@ -60,7 +60,7 @@ public_headers = [
6060
'printbuf.h',
6161
]
6262

63-
sources = [
63+
sources = files(
6464
'arraylist.c',
6565
'debug.c',
6666
'json_c_version.c',
@@ -74,9 +74,11 @@ sources = [
7474
'printbuf.c',
7575
'random_seed.c',
7676
'strerror_override.c',
77-
]
77+
)
7878

79-
libjson_c = library(meson.project_name(), json_config_h, json_h, config_h, sources,
79+
libjson_c = library(
80+
'json-c',
81+
sources,
8082
include_directories: inc,
8183
install: true,
8284
)
@@ -88,14 +90,13 @@ json_c_dep = declare_dependency(
8890
sources: json_config_h,
8991
)
9092

91-
header_subdir = 'json-c'
92-
install_headers(public_headers, subdir: header_subdir)
93+
install_headers(public_headers, subdir: 'json-c')
9394

9495
pkgconfig = import('pkgconfig')
9596
pkgconfig.generate(libjson_c,
9697
description: 'A JSON implementation in C',
9798
version: meson.project_version(),
9899
filebase: meson.project_name(),
99100
name: meson.project_name(),
100-
subdirs: header_subdir,
101+
subdirs: 'json-c',
101102
)

0 commit comments

Comments
 (0)