Description of problem: A check for the presence of glib2-devel package fails when building s390utils in rawhide with -Werror. There is no such problem in F-37, so either something changed in glib2 2.75 or rather gcc 13 is smarter ... <mock-chroot> sh-5.2# cat test.c #include <glib.h> int main(void) { return 0; } <mock-chroot> sh-5.2# gcc -g -fstack-protector-all -W -Wall -Wformat-security -O3 -std=gnu11 -DOPENSSL_API_COMPAT=0x10101000L -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -pthread -Wall -Wextra -Wshadow -Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -Wno-long-long -Wuninitialized -Wconversion -Wstrict-prototypes -Wpointer-arith -Wno-error=inline -Wno-unused-function -Wno-unused-parameter -Wno-unused-variable -Werror -fPIC -I ../include -D_GNU_SOURCE -c test.c In file included from /usr/include/glib-2.0/glib/giochannel.h:36, from /usr/include/glib-2.0/glib.h:56, from test.c:1: /usr/include/glib-2.0/glib/gstring.h: In function ‘g_string_append_len_inline’: /usr/include/glib-2.0/glib/gstring.h:217:11: error: conversion to ‘gssize’ {aka ‘long int’} from ‘size_t’ {aka ‘long unsigned int’} may change the sign of the result [-Werror=sign-conversion] 217 | len = strlen (val); | ^~~~~~ In file included from /usr/lib64/glib-2.0/include/glibconfig.h:9, from /usr/include/glib-2.0/glib/gtypes.h:34, from /usr/include/glib-2.0/glib/galloca.h:34, from /usr/include/glib-2.0/glib.h:32: /usr/include/glib-2.0/glib/gstring.h:219:30: error: conversion to ‘long unsigned int’ from ‘gssize’ {aka ‘long int’} may change the sign of the result [-Werror=sign-conversion] 219 | if (G_LIKELY (gstring->len + len < gstring->allocated_len)) | ^ /usr/include/glib-2.0/glib/gmacros.h:1238:8: note: in definition of macro ‘_G_BOOLEAN_EXPR_IMPL’ 1238 | if (expr) \ | ^~~~ /usr/include/glib-2.0/glib/gmacros.h:1245:43: note: in expansion of macro ‘_G_BOOLEAN_EXPR’ 1245 | #define G_LIKELY(expr) (__builtin_expect (_G_BOOLEAN_EXPR(expr), 1)) | ^~~~~~~~~~~~~~~ /usr/include/glib-2.0/glib/gstring.h:219:7: note: in expansion of macro ‘G_LIKELY’ 219 | if (G_LIKELY (gstring->len + len < gstring->allocated_len)) | ^~~~~~~~ /usr/include/glib-2.0/glib/gstring.h:223:27: error: conversion to ‘size_t’ {aka ‘long unsigned int’} from ‘gssize’ {aka ‘long int’} may change the sign of the result [-Werror=sign-conversion] 223 | memcpy (end, val, len); | ^~~ /usr/include/glib-2.0/glib/gstring.h:225:28: error: conversion to ‘size_t’ {aka ‘long unsigned int’} from ‘gssize’ {aka ‘long int’} may change the sign of the result [-Werror=sign-conversion] 225 | memmove (end, val, len); | ^~~ /usr/include/glib-2.0/glib/gstring.h:226:20: error: conversion to ‘long unsigned int’ from ‘gssize’ {aka ‘long int’} may change the sign of the result [-Werror=sign-conversion] 226 | gstring->len += len; | ^~ cc1: all warnings being treated as errors Version-Release number of selected component (if applicable): gcc-13.0.1-0.2.fc38.s390x glib2-2.75.3-3.fc39.s390x
This doesn't seem to be s390x specific, it reproduced on ppc64le and x86_64 as well.
resolved via an upstream issue, closing