pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/54909: glib2 build fails for gsize type
>Number: 54909
>Category: pkg
>Synopsis: glib2 build fails for gsize type
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Jan 30 05:40:00 +0000 2020
>Originator: Michael van Elst
>Release: NetBSD 9.0
>Organization:
>Environment:
System: NetBSD egghed 9.0 NetBSD 9.0 (LIBKVER) #0: Tue Jan 19 00:00:00 UTC 2038 root@localhost:/sys/arch/evbarm/compile/LIBKVER evbarm
Architecture: earmv6hf
Machine: evbarm
>Description:
Build of glib2 in a netbsd-9 chroot on earmv6hf fails with:
In file included from ../glib/galloca.h:32:0,
from ../glib/glib.h:30,
from ../glib/tests/overflow.c:14:
../glib/gtypes.h:475:24: note: expected 'guint32 * {aka unsigned int *}' but argument is of type 'gsize * {aka long unsigned int *}'
static inline gboolean _GLIB_CHECKED_ADD_U32 (guint32 *dest, guint32 a, guint32 b) {
^~~~~~~~~~~~~~~~~~~~~
In file included from ../glib/glib.h:85:0,
from ../glib/tests/overflow.c:14:
../glib/tests/overflow.c: In function 'test_checked_gsize_mul':
../glib/tests/overflow.c:180:67: warning: passing argument 1 of '_GLIB_CHECKED_MUL_U32' from incompatible pointer type [-Wincompatible-pointer-types]
This is caused by netbsd-9 gcc defining
#define __SIZE_TYPE__ long unsigned int
on this 32bit system and a patch we apply to glib2 forces it to use size_t as
the gsize type.
The glib2 upstream code doesn't trust size_t but deduces the shortest integer
type that matches size_t (which is 'unsigned int' not 'long unsigned int')
and the glib2 code then relies on that decision.
The patch was introduced to solve pkg/54298. So reverting this will
probably cause build problems on netbsd-8 again.
>How-To-Repeat:
Build glib2 package on NetBSD-9 on earm6hf (or possibly any 32bit arch).
>Fix:
>Unformatted:
Home |
Main Index |
Thread Index |
Old Index