x86_64-pc-linux-gnu-gcc -march=haswell -O2 -pipe -DBIN_DIR=\"/sbin\" -DLIB_STRING=\"lib64\" -DRUN_DIR=\"run\" -MMD -MP -fPIC -fvisibility=hidden -I../libdmmp -I../libmpathcmd -I/usr/include/json-c -c -o libdmmp_p g.o libdmmp_pg.c In file included from libdmmp.c:37: libdmmp.c: In function 'dmmp_mpath_array_get': libdmmp_private.h:85:59: error: 'TRUE' undeclared (first use in this function) 85 | if (json_object_object_get_ex(j_obj, key, &j_obj_tmp) != TRUE) { \ | ^~~~ libdmmp.c:205:2: note: in expansion of macro '_json_obj_get_value' 205 | _json_obj_get_value(ctx, j_obj, cur_json_major_version, | ^~~~~~~~~~~~~~~~~~~ libdmmp_private.h:85:59: note: each undeclared identifier is reported only once for each function it appears in 85 | if (json_object_object_get_ex(j_obj, key, &j_obj_tmp) != TRUE) { \ | ^~~~ libdmmp.c:205:2: note: in expansion of macro '_json_obj_get_value' 205 | _json_obj_get_value(ctx, j_obj, cur_json_major_version, | ^~~~~~~~~~~~~~~~~~~ ... Reproducible: Always Steps to Reproduce: 1. Update json-c to 0.14 2. recompile sys-fs/multipath-tools Actual Results: Compiler has undefined symbol TRUE Patched multipath-tools-0.8.3/libdmmp/libdmmp_private.h manually to contain a line #define TRUE 0 after having had a look at the source of json-c. Compiled and installed fine, but I'm unsre if it should be fixed in dev-libs/json-c or multipath-tools.
json-c removed the TRUE/FALSE end of 2017 in https://github.com/json-c/json-c/commit/0992aac61f8b087efd7094e9ac2b84fa9c040fcd Looks like it needs to be fixed in multipath-tools to me.
Thanks Kobboi, then it only needs to be fixed in libdmmp/libdmmp_private.h, as I did a recursive grep and only found the occurences there.
Patch from Fedora: https://src.fedoraproject.org/rpms/device-mapper-multipath/blob/master/f/0032-add-support-for-upcoming-json-c-0.14.0.patch
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6e3a04d1532db375c74b38c71963316ef4a466f0 commit 6e3a04d1532db375c74b38c71963316ef4a466f0 Author: Thomas Deutschmann <whissi@gentoo.org> AuthorDate: 2020-05-02 07:28:43 +0000 Commit: Thomas Deutschmann <whissi@gentoo.org> CommitDate: 2020-05-02 07:28:59 +0000 sys-fs/multipath-tools: add json-c-0.14 support Closes: https://bugs.gentoo.org/720330 Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: Thomas Deutschmann <whissi@gentoo.org> .../files/multipath-tools-0.8.3-json-c-0.14.patch | 28 +++++++ .../multipath-tools-0.8.3-r2.ebuild | 92 ++++++++++++++++++++++ 2 files changed, 120 insertions(+)