Bugzilla – Bug 1221700
GCC 14: libcomps package fails
Last modified: 2024-07-10 14:09:13 UTC
Building libcomps with GCC 14 fails here: https://build.opensuse.org/package/live_build_log/openSUSE:Factory:Staging:Gcc7/libcomps/standard/x86_64 Due to (exhaustive list of errors): libcomps-0.1.20/libcomps/tests/check_parse.c: In function ‘test_arch_fn’: libcomps-0.1.20/libcomps/tests/check_parse.c:588:11: error: assignment to ‘COMPS_DocGroup *’ from incompatible pointer type ‘COMPS_DocCategory *’ [-Wincompatible-pointer-types] 588 | g = (COMPS_DocCategory*)it->comps_obj; | ^ libcomps-0.1.20/libcomps/tests/check_parse.c:589:52: error: passing argument 1 of ‘comps_doccategory_get_id’ from incompatible pointer type [-Wincompatible-pointer-types] 589 | str = (COMPS_Str*)comps_doccategory_get_id(g); | ^ | | | COMPS_DocGroup * In file included from /home/abuild/rpmbuild/BUILD/libcomps-0.1.20/libcomps/tests/../src/comps_objradix.h:28, from /home/abuild/rpmbuild/BUILD/libcomps-0.1.20/libcomps/tests/../src/comps_objdict.h:32, from /home/abuild/rpmbuild/BUILD/libcomps-0.1.20/libcomps/tests/../src/comps_doc.h:24, from /home/abuild/rpmbuild/BUILD/libcomps-0.1.20/libcomps/tests/check_parse.c:23: libcomps-0.1.20/libcomps/tests/../src/comps_doccategory.h:110:24: note: expected ‘COMPS_DocCategory *’ but argument is of type ‘COMPS_DocGroup *’ 110 | HEAD_COMPS_PROP_GETTER(category, COMPS_DocCategory, id) /*comps_utils.h macro*/ | libcomps-0.1.20/libcomps/tests/../src/comps_utils.h:94:71: note: in definition of macro ‘HEAD_COMPS_PROP_GETTER’ 94 | (OBJTYPE *OBJNAME); | ^~~~~~~ libcomps-0.1.20/libcomps/tests/check_parse.c:608:11: error: assignment to ‘COMPS_DocGroup *’ from incompatible pointer type ‘COMPS_DocEnv *’ [-Wincompatible-pointer-types] 608 | g = (COMPS_DocEnv*)it->comps_obj; | ^ libcomps-0.1.20/libcomps/tests/check_parse.c:609:47: error: passing argument 1 of ‘comps_docenv_get_id’ from incompatible pointer type [-Wincompatible-pointer-types] 609 | str = (COMPS_Str*)comps_docenv_get_id(g); | ^ | | | COMPS_DocGroup * libcomps-0.1.20/libcomps/tests/../src/comps_docenv.h:92:24: note: expected ‘COMPS_DocEnv *’ but argument is of type ‘COMPS_DocGroup *’ 92 | HEAD_COMPS_PROP_GETTER(env, COMPS_DocEnv, id) /*comps_utils.h macro*/ | See the meta bug#1220571 for more info.
*** Bug 1225796 has been marked as a duplicate of this bug. ***
According to https://gitlab.com/fweimer-rh/fedora-modernc/-/blob/main/pkg/l/libcomps.md?ref_type=heads we perhaps need https://github.com/rpm-software-management/libcomps/commit/a71bce7e62990550a57688e51b14eb82d6de196b
I have created https://build.opensuse.org/request/show/1186618 with the patch referenced in the previous comment.