]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
json-c: upgrade 0.16 -> 0.17
authorAlexander Kanavin <alex.kanavin@gmail.com>
Fri, 22 Sep 2023 07:24:10 +0000 (09:24 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 26 Sep 2023 09:35:07 +0000 (10:35 +0100)
Fix run-ptest to append to log instead of overwriting it with every test invocation.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/json-c/json-c/0001-Fix-build-with-clang-15.patch [deleted file]
meta/recipes-devtools/json-c/json-c/run-ptest
meta/recipes-devtools/json-c/json-c_0.17.bb [moved from meta/recipes-devtools/json-c/json-c_0.16.bb with 73% similarity]

diff --git a/meta/recipes-devtools/json-c/json-c/0001-Fix-build-with-clang-15.patch b/meta/recipes-devtools/json-c/json-c/0001-Fix-build-with-clang-15.patch
deleted file mode 100644 (file)
index 215f4d8..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-From 0145b575ac1fe6a77e00d639864f26fc91ceb12f Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 13 Aug 2022 20:37:03 -0700
-Subject: [PATCH] Fix build with clang-15+
-
-Fixes
-json_util.c:63:35: error: a function declaration without a prototype is deprecated in all versions of C [-We
-rror,-Wstrict-prototypes]
-const char *json_util_get_last_err()
-                                  ^
-                                   void
-
-Upstream-Status: Backport [https://github.com/json-c/json-c/pull/783]
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- json_util.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/json_util.c b/json_util.c
-index 952770a..83d9c68 100644
---- a/json_util.c
-+++ b/json_util.c
-@@ -60,7 +60,7 @@ static int _json_object_to_fd(int fd, struct json_object *obj, int flags, const
- static char _last_err[256] = "";
--const char *json_util_get_last_err()
-+const char *json_util_get_last_err(void)
- {
-       if (_last_err[0] == '\0')
-               return NULL;
--- 
-2.37.2
-
index 9ee6095ea22c6f267070fba6f5166800ef0c9a47..2d0e94cd3ac1563c2d8718b7de135051823f4030 100644 (file)
@@ -8,7 +8,7 @@ for i in test*.test; do
     # test_basic is not an own testcase, just
     # contains common code of other tests
     if [ "$i" != "test_basic.test" ]; then
-        if ./$i > json-c_test.log 2>&1 ; then
+        if ./$i >> json-c_test.log 2>&1 ; then
             echo PASS: $i
         else
             ret_val=1
similarity index 73%
rename from meta/recipes-devtools/json-c/json-c_0.16.bb
rename to meta/recipes-devtools/json-c/json-c_0.17.bb
index 3aba41dfcf64d138c787c032c5ec4d49a049fa55..b7b596212f8a1cd5fdaac2020c28c316cbbbeb46 100644 (file)
@@ -4,12 +4,10 @@ HOMEPAGE = "https://github.com/json-c/json-c/wiki"
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://COPYING;md5=de54b60fbbc35123ba193fea8ee216f2"
 
-SRC_URI = " \
-    https://s3.amazonaws.com/json-c_releases/releases/${BP}.tar.gz \
-    file://0001-Fix-build-with-clang-15.patch \
-    file://run-ptest \
-"
-SRC_URI[sha256sum] = "8e45ac8f96ec7791eaf3bb7ee50e9c2100bbbc87b8d0f1d030c5ba8a0288d96b"
+SRC_URI = "https://s3.amazonaws.com/json-c_releases/releases/${BP}.tar.gz \
+           file://run-ptest \
+           "
+SRC_URI[sha256sum] = "7550914d58fb63b2c3546f3ccfbe11f1c094147bd31a69dcd23714d7956159e6"
 
 UPSTREAM_CHECK_URI = "https://github.com/${BPN}/${BPN}/tags"
 UPSTREAM_CHECK_REGEX = "json-c-(?P<pver>\d+(\.\d+)+)-\d+"
@@ -24,7 +22,7 @@ do_install_ptest() {
     install ${S}/tests/*.test ${D}/${PTEST_PATH}/tests
     install ${S}/tests/*.expected ${D}/${PTEST_PATH}/tests
     install ${S}/tests/test-defs.sh ${D}/${PTEST_PATH}/tests
-    install ${S}/tests/valid*json ${D}/${PTEST_PATH}/tests
+    install ${S}/tests/*json ${D}/${PTEST_PATH}/tests
 }
 
 BBCLASSEXTEND = "native nativesdk"