building on s390 fails due to G_GSIZE_FORMAT mismatches
building on s390 (32-bit) fails:
../glib/gslice.c:1527:26: error: format ‘%u’ expects argument of type ‘unsigned int’, but argument 4 has type ‘size_t’ {aka ‘long unsigned int’} [-Werror=format=]
1527 | g_fprintf (stderr, "GSlice: MemChecker: attempt to release non-allocated block: %p size=%" G_GSIZE_FORMAT "\n", pointer, size);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~
| |
| size_t {aka long unsigned int}
hacking the glibconfig.h to use standard size types works fine though.
typedef ssize_t gssize;
typedef size_t gsize;
#define G_GSIZE_MODIFIER "z"
#define G_GSSIZE_MODIFIER "z"
#define G_GSIZE_FORMAT "zu"
#define G_GSSIZE_FORMAT "zi"
reproduction is pretty straight forward:
$ tar xf glib-2.60.7.tar.xz
$ cd glib-2.60.7
$ meson --buildtype plain . build
...
$ ninja -C build
...build fail...
Edited by Philip Withnall