NetBSD Problem Report #54298
From john@hlin.zia.io Mon Jun 17 01:48:21 2019
Return-Path: <john@hlin.zia.io>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id 54E327A155
for <gnats-bugs@gnats.NetBSD.org>; Mon, 17 Jun 2019 01:48:21 +0000 (UTC)
Message-Id: <201906170139.x5H1devJ016364@hlin.zia.io>
Date: Mon, 17 Jun 2019 01:39:40 GMT
From: john@ziaspace.com
Reply-To: john@ziaspace.com
To: gnats-bugs@NetBSD.org
Subject: devel/glib2 fails to build
X-Send-Pr-Version: 3.95
>Number: 54298
>Category: pkg
>Synopsis: devel/glib2 fails to build
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: prlw1
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Jun 17 01:50:00 +0000 2019
>Closed-Date: Thu Aug 01 15:46:11 +0000 2019
>Last-Modified: Fri Feb 07 17:10:01 +0000 2020
>Originator: John Klos
>Release: NetBSD 8.0_BETA
>Organization:
>Environment:
System: NetBSD hlin.zia.io 8.0_BETA NetBSD 8.0_BETA (HLIN) #0: Fri Jul 27 17:29:37 UTC 2018 john@helena.zia.io:/usr/netbsd-8_BETA/obj-evbarm/sys/arch/evbarm/compile/HLIN evbarm
Architecture: earmv7hf
Machine: evbarm
>Description:
Compiling devel/glib2 on earmv7hf (NetBSD 8 from a year ago and from now) fails with:
[76/578] Compiling C object 'glib/4430778@@glib-2.0@sha/gmem.c.o'.
../glib/gmem.c:51:3: warning: initialization from incompatible pointer type
[-Wincompatible-pointer-types]
malloc,
^
../glib/gmem.c:51:3: note: (near initialization for 'glib_mem_vtable.malloc')
../glib/gmem.c:52:3: warning: initialization from incompatible pointer type
[-Wincompatible-pointer-types]
realloc,
^
../glib/gmem.c:52:3: note: (near initialization for 'glib_mem_vtable.realloc')
../glib/gmem.c:54:3: warning: initialization from incompatible pointer type
[-Wincompatible-pointer-types]
calloc,
^
../glib/gmem.c:54:3: note: (near initialization for 'glib_mem_vtable.calloc')
../glib/gmem.c:55:3: warning: initialization from incompatible pointer type
[-Wincompatible-pointer-types]
malloc,
^
../glib/gmem.c:55:3: note: (near initialization for 'glib_mem_vtable.try_malloc')
../glib/gmem.c:56:3: warning: initialization from incompatible pointer type
[-Wincompatible-pointer-types]
realloc,
^
../glib/gmem.c:56:3: note: (near initialization for 'glib_mem_vtable.try_reallo')
[98/578] Compiling C object 'glib/4430778@@glib-2.0@sha/gslice.c.o'.
FAILED: glib/4430778@@glib-2.0@sha/gslice.c.o
gcc -Iglib/4430778@@glib-2.0@sha -Iglib -I../glib -I. -I../ -I/usr/local/include
-I/usr/include -I/usr/local/include/python3.7 -fdiagnostics-color=always -pipe
-D_FILE_OFFSET_BITS=64 -std=gnu89 -D_GNU_SOURCE -fno-strict-aliasing -Wall
-Wstrict-prototypes -Wunused -Wno-bad-function-cast -Wno-pedantic
-Werror=declaration-after-statement -Werror=format=2 -Werror=implicit-function-declaration
-Werror=init-self -Werror=missing-include-dirs -Werror=missing-prototypes
-Werror=pointer-arith -O2 -D_FORTIFY_SOURCE=2 -fPIC -pthread '-DG_LOG_DOMAIN="GLib"'
-DGLIB_COMPILATION -fvisibility=hidden -MD -MQ 'glib/4430778@@glib-2.0@sha/gslice.c.o' -MF
'glib/4430778@@glib-2.0@sha/gslice.c.o.d' -o 'glib/4430778@@glib-2.0@sha/gslice.c.o' -c
../glib/gslice.c
../glib/gslice.c: In function 'smc_notify_free':
../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=]
g_fprintf (stderr, "GSlice: MemChecker: attempt to release non-allocated block: %p
size=%" G_GSIZE_FORMAT "\n", pointer, size);
^
../glib/gslice.c:1532:26: error: format '%u' expects argument of type 'unsigned int', but
argument 4 has type 'SmcVType {aka long unsigned int}' [-Werror=format=]
g_fprintf (stderr, "GSlice: MemChecker: attempt to release block with invalid size:
%p size=%" G_GSIZE_FORMAT " invalid-size=%" G_GSIZE_FORMAT "\n", pointer, real_size, size);
^
../glib/gslice.c:1532:26: error: format '%u' expects argument of type 'unsigned int', but
argument 5 has type 'size_t {aka long unsigned int}' [-Werror=format=]
../glib/gslice.c:1537:26: error: format '%u' expects argument of type 'unsigned int', but
argument 4 has type 'size_t {aka long unsigned int}' [-Werror=format=]
g_fprintf (stderr, "GSlice: MemChecker: attempt to release non-allocated block: %p
size=%" G_GSIZE_FORMAT "\n", pointer, size);
^
cc1: some warnings being treated as errors
[103/578] Compiling C object 'glib/4430778@@glib-2.0@sha/gstrfuncs.c.o'.
ninja: build stopped: subcommand failed.
*** Error code 1
Stop.
earm NetBSD 8 fails with:
[50/578] Compiling C object 'glib/4430778@@glib-2.0@sha/gatomic.c.o'.
FAILED: glib/4430778@@glib-2.0@sha/gatomic.c.o
gcc -Iglib/4430778@@glib-2.0@sha -Iglib -I../glib -I. -I../ -I/usr/local/include
-I/usr/include -I/usr/local/include/python3.7 -fdiagnostics-color=always -pipe
-D_FILE_OFFSET_BITS=64 -std=gnu89 -D_GNU_SOURCE -fno-strict-aliasing -Wall
-Wstrict-prototypes -Wunused -Wno-bad-function-cast -Wno-pedantic
-Werror=declaration-after-statement -Werror=format=2 -Werror=implicit-function-declaration
-Werror=init-self -Werror=missing-include-dirs -Werror=missing-prototypes
-Werror=pointer-arith -O2 -D_FORTIFY_SOURCE=2 -fPIC -pthread '-DG_LOG_DOMAIN="GLib"'
-DGLIB_COMPILATION -fvisibility=hidden -MD -MQ 'glib/4430778@@glib-2.0@sha/gatomic.c.o' -MF
'glib/4430778@@glib-2.0@sha/gatomic.c.o.d' -o 'glib/4430778@@glib-2.0@sha/gatomic.c.o' -c
../glib/gatomic.c
../glib/gatomic.c:675:2: error: #error G_ATOMIC_LOCK_FREE defined, but incapable of
lock-free atomics.
#error G_ATOMIC_LOCK_FREE defined, but incapable of lock-free atomics.
^
[51/578] Compiling C object 'tests/59830eb@@onceinit@exe/onceinit.c.o'.
ninja: build stopped: subcommand failed.
*** Error code 1
Stop.
make[1]: stopped in /usr/pkgsrc/devel/glib2
*** Error code 1
Stop.
make: stopped in /usr/pkgsrc/devel/glib2
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: pkg-manager->prlw1
Responsible-Changed-By: leot@NetBSD.org
Responsible-Changed-When: Tue, 18 Jun 2019 08:36:30 +0000
Responsible-Changed-Why:
Patrick, can you please give it a look?
(over to MAINTAINER)
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 18 Jun 2019 10:45:46 +0100
To check, all on NetBSD-8, you have 3 problems:
1) earmv7hf warning about incompatible pointer types for malloc & friends
2) earmv7hf size_t printf format string
3) earm atomics
Trying the easy one first, 2) looks strange. Could you
cat > meson.build << EOF
project('PR54298', 'c')
compiler = meson.get_compiler('c')
sizet_size = compiler.sizeof('size_t')
message('sizeof(size_t) = @0@'.format(sizet_size))
EOF
mkdir output
meson output
cat > foo.c << EOF
#include <stdio.h>
int main()
{
printf("sizeof(size_t) = %zu\n", sizeof(size_t));
return 0;
}
EOF
gcc -o foo foo.c
./foo
Really odd if they don't match, but that's all I can think of!
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 18 Jun 2019 10:59:56 +0100
To check 3) could you try
cat > bar.c << EOF
int main() {
volatile int atomic = 2;
__sync_bool_compare_and_swap (&atomic, 2, 3);
return 0;
}
EOF
gcc -o bar bar.c
Apparently if that compiles, "atomic ops" are available?
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 18 Jun 2019 10:54:36 +0100
1) Is related to 2): malloc(gsize) vs malloc(size_t), and they should come
out the same.
From: John Klos <john@ziaspace.com>
To: gnats-bugs@netbsd.org
Cc: prlw1@netbsd.org, pkgsrc-bugs@netbsd.org
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 18 Jun 2019 16:34:19 +0000 (UTC)
> Trying the easy one first, 2) looks strange. Could you
...
> meson output
The Meson build system
Version: 0.50.1
Source dir: /home/john
Build dir: /home/john/output
Build type: native build
Project name: PR54298
Project version: undefined
Native C compiler: cc (gcc 5.5.0 "cc (nb3 20180905) 5.5.0")
WARNING: Unknown CPU family 'evbarm', please report this at
https://github.com/mesonbuild/meson/issues/new with theoutput of `uname
-a` and `cat /proc/cpuinfo`
Build machine cpu family: evbarm
Build machine cpu: evbarm
Checking for size of "size_t" : 4
Message: sizeof(size_t) = 4
Build targets in project: 0
Found ninja-1.9.0 at /usr/local/bin/ninja
> ./foo
sizeof(size_t) = 4
John
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Wed, 19 Jun 2019 17:17:09 +0100
So why wasn't the compile happy with %u ?
Could you please attach /usr/pkg/lib/glib-2.0/include/glibconfig.h ?
(Or is yours in /usr/local/lib/glib-2.0... ?)
To me this is looking like an overzealous compiler warning. On the
other hand size_t is standard C99. %z apparently is even supported
on windows since VS2015, so one could ask why not simply typedef size_t gsize.
State-Changed-From-To: open->feedback
State-Changed-By: prlw1@NetBSD.org
State-Changed-When: Fri, 21 Jun 2019 20:26:39 +0000
State-Changed-Why:
I thought I would try myself, but my raspberry pi's sd card holder just
broke. Could you try the __sync_bool_compare_and_swap test and send the
glibconfig.h file as mentioned above?
From: "John D. Baker" <jdbaker@consolidated.net>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Sun, 23 Jun 2019 22:23:04 -0500 (CDT)
John Klos wrote:
> [50/578] Compiling C object 'glib/4430778@@glib-2.0@sha/gatomic.c.o'.
> FAILED: glib/4430778@@glib-2.0@sha/gatomic.c.o
> gcc -Iglib/4430778@@glib-2.0@sha -Iglib -I../glib -I. -I../ -I/usr/local/include
> -I/usr/include -I/usr/local/include/python3.7 -fdiagnostics-color=always -pipe
> -D_FILE_OFFSET_BITS=64 -std=gnu89 -D_GNU_SOURCE -fno-strict-aliasing -Wall
> -Wstrict-prototypes -Wunused -Wno-bad-function-cast -Wno-pedantic
> -Werror=declaration-after-statement -Werror=format=2 -Werror=implicit-function-declaration
> -Werror=init-self -Werror=missing-include-dirs -Werror=missing-prototypes
> -Werror=pointer-arith -O2 -D_FORTIFY_SOURCE=2 -fPIC -pthread '-DG_LOG_DOMAIN="GLib"'
> -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ 'glib/4430778@@glib-2.0@sha/gatomic.c.o' -MF
> 'glib/4430778@@glib-2.0@sha/gatomic.c.o.d' -o 'glib/4430778@@glib-2.0@sha/gatomic.c.o' -c
> ../glib/gatomic.c
> ../glib/gatomic.c:675:2: error: #error G_ATOMIC_LOCK_FREE defined, but incapable of
> lock-free atomics.
> #error G_ATOMIC_LOCK_FREE defined, but incapable of lock-free atomics.
> ^
> [51/578] Compiling C object 'tests/59830eb@@onceinit@exe/onceinit.c.o'.
> ninja: build stopped: subcommand failed.
> *** Error code 1
>
> Stop.
> make[1]: stopped in /usr/pkgsrc/devel/glib2
> *** Error code 1
>
> Stop.
> make: stopped in /usr/pkgsrc/devel/glib2
I see this as well on NetBSD/sparc-7.2_STABLE. Probably on netbsd-8/sparc
and -current/sparc as well, but I haven't gotten around to updating
packages on those yet.
--
|/"\ John D. Baker, KN5UKS NetBSD Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net OpenBSD FreeBSD
| X No HTML/proprietary data in email. BSD just sits there and works!
|/ \ GPGkeyID: D703 4A7E 479F 63F8 D3F4 BD99 9572 8F23 E4AD 1645
From: "John D. Baker" <jdbaker@consolidated.net>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Sun, 23 Jun 2019 22:39:41 -0500 (CDT)
prlw1@NetBSD.org writes:
> Could you try the __sync_bool_compare_and_swap test and send the
On NetBSD/sparc-7.2_STABLE, the test file compiles without complaint.
> glibconfig.h file as mentioned above?
I'll see about that when my 'pkg_rolling-replace' gets around to trying
to build "devel/glib2" again.
--
|/"\ John D. Baker, KN5UKS NetBSD Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net OpenBSD FreeBSD
| X No HTML/proprietary data in email. BSD just sits there and works!
|/ \ GPGkeyID: D703 4A7E 479F 63F8 D3F4 BD99 9572 8F23 E4AD 1645
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 10:12:44 +0100
On Mon, Jun 24, 2019 at 03:40:01AM +0000, John D. Baker wrote:
> prlw1@NetBSD.org writes:
>
> > Could you try the __sync_bool_compare_and_swap test and send the
>
> On NetBSD/sparc-7.2_STABLE, the test file compiles without complaint.
I need help with this part: meson checks for
__sync_bool_compare_and_swap. You find that this compiles without
complaint, so meson is right to set G_ATOMIC_LOCK_FREE.
glib then also tests for __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 and
fails if it isn't defined.
What is the relationship between __sync_bool_compare_and_swap() and
the macro __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4?
(I'll try to paper over this by making meson also test for the macro.)
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 10:22:21 +0100
On Tue, Jun 25, 2019 at 09:15:01AM +0000, Patrick Welche wrote:
> (I'll try to paper over this by making meson also test for the macro.)
Actually, meson.build already tests for this.
int main() {
volatile int atomic = 2;
__sync_bool_compare_and_swap (&atomic, 2, 3);
return 0;
}
compiled successfully for you. How about
#ifndef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4
#error "compiler has atomic ops, but doesn't define __GCC_HAVE_SYNC_COMPARE_AND_
SWAP_4"
#endif
?
(If yes, then gatomic.c should compile too.)
From: "Patrick Welche" <prlw1@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/54298 CVS commit: pkgsrc/devel/glib2
Date: Tue, 25 Jun 2019 10:57:28 +0000
Module Name: pkgsrc
Committed By: prlw1
Date: Tue Jun 25 10:57:28 UTC 2019
Modified Files:
pkgsrc/devel/glib2: Makefile distinfo
Added Files:
pkgsrc/devel/glib2/patches: patch-glib_glibconfig.h.in
patch-glib_gtypes.h
Log Message:
glib2 is built with USE_LANGUAGES c99, so size_t exists. Use it rather
than a type of the same size.
PR pkg/54298
To generate a diff of this commit:
cvs rdiff -u -r1.254 -r1.255 pkgsrc/devel/glib2/Makefile
cvs rdiff -u -r1.248 -r1.249 pkgsrc/devel/glib2/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/devel/glib2/patches/patch-glib_glibconfig.h.in \
pkgsrc/devel/glib2/patches/patch-glib_gtypes.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
From: "John D. Baker" <jdbaker@consolidated.net>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 05:57:45 -0500 (CDT)
Patrick Welche <prlw1@cam.ac.uk> wrote:
> How about
> #ifndef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4
> #error "compiler has atomic ops, but doesn't define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4"
> #endif
Looks like that's a problem:
$ cat baz.c
#ifndef __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4
#error "compiler has atomic ops, but doesn't define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4"
#endif
$ gcc -o baz baz.c
baz.c:2:2: error: #error "compiler has atomic ops, but doesn't define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4"
#error "compiler has atomic ops, but doesn't define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4"
^
--
|/"\ John D. Baker, KN5UKS NetBSD Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net OpenBSD FreeBSD
| X No HTML/proprietary data in email. BSD just sits there and works!
|/ \ GPGkeyID: D703 4A7E 479F 63F8 D3F4 BD99 9572 8F23 E4AD 1645
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 11:59:00 +0100
Given that I can't reproduce any of the problems here, could one of you
test glib2-2.60.4nb3 to see if that fixes parts 1) and 2) ?
From: Patrick Welche <prlw1@cam.ac.uk>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 12:22:52 +0100
Does this help?
Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/devel/glib2/distinfo,v
retrieving revision 1.249
diff -u -r1.249 distinfo
--- distinfo 25 Jun 2019 10:57:28 -0000 1.249
+++ distinfo 25 Jun 2019 11:20:59 -0000
@@ -26,4 +26,4 @@
SHA1 (patch-gmodule_gmodule.c) = 55c5f9d16e3517f3fdc04d40922f50d9c66b0b9a
SHA1 (patch-gobject_glib-mkenums.in) = c177cf9b1ea81542665240678f47f68351a3760d
SHA1 (patch-gobject_meson.build) = 58ee162e44047bf20c66067fd3edbe98cc13af50
-SHA1 (patch-meson.build) = ce24f19714f6d78d1be9ecd6802f6c25a086c8e8
+SHA1 (patch-meson.build) = c73d83cc9f717bdafd693685168990dc8eaf6b2a
Index: patches/patch-meson.build
===================================================================
RCS file: /cvsroot/pkgsrc/devel/glib2/patches/patch-meson.build,v
retrieving revision 1.4
diff -u -r1.4 patch-meson.build
--- patches/patch-meson.build 18 Jun 2019 13:05:14 -0000 1.4
+++ patches/patch-meson.build 25 Jun 2019 11:20:59 -0000
@@ -1,19 +1,34 @@
-$NetBSD: patch-meson.build,v 1.4 2019/06/18 13:05:14 jperkin Exp $
+$NetBSD$
- Don't insist that python binary is called "python3".
(Requires meson >= 0.50.0)
- Don't install bash completion scripts.
- Tolerate getxattr not existing (smartOS)
-https://gitlab.gnome.org/GNOME/glib/merge_requests/888
+ https://gitlab.gnome.org/GNOME/glib/merge_requests/888
- Define a newer POSIX, as we build this package with -std=gnu99
- auto-detect GNU iconv, even if no arguments are passed.
(by checking if iconv.h might in fact be a gnu one)
+- Don't restrict lack of __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4
+ fix to android and linux. PR pkg/54298
+
--- meson.build.orig 2019-06-10 17:47:20.000000000 +0000
+++ meson.build
-@@ -1696,14 +1696,14 @@ else
+@@ -1579,10 +1579,7 @@ atomicdefine = '''
+ # We know that we can always use real ("lock free") atomic operations with MSVC
+ if cc.get_id() == 'msvc' or cc.links(atomictest, name : 'atomic ops')
+ have_atomic_lock_free = true
+- if (host_system == 'android' or host_system == 'linux') and not cc.compiles(atomicdefine, name : 'atomic ops define')
+- # When building for armv5 on Linux, gcc provides
+- # __sync_bool_compare_and_swap but doesn't define
+- # __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4
++ if not cc.compiles(atomicdefine, name : 'atomic ops define')
+ glib_conf.set('__GCC_HAVE_SYNC_COMPARE_AND_SWAP_4', true)
+ endif
+ else
+@@ -1696,14 +1693,14 @@ else
found_iconv = false
if iconv_opt == 'libc'
if cc.has_function('iconv_open')
@@ -36,7 +51,7 @@
endif
elif iconv_opt == 'native'
if cc.has_header_symbol('iconv.h', 'iconv_open')
-@@ -1785,7 +1785,7 @@ endif
+@@ -1785,7 +1782,7 @@ endif
# proxy-libintl subproject.
# FIXME: glib-gettext.m4 has much more checks to detect broken/uncompatible
# implementations. This could be extended if issues are found in some platforms.
@@ -45,7 +60,7 @@
libintl = []
have_bind_textdomain_codeset = cc.has_function('bind_textdomain_codeset')
else
-@@ -1836,16 +1836,15 @@ if host_system != 'windows' and get_opti
+@@ -1836,16 +1833,15 @@ if host_system != 'windows' and get_opti
if cc.has_function('getxattr') and cc.has_header('sys/xattr.h')
glib_conf.set('HAVE_SYS_XATTR_H', 1)
glib_conf_prefix = glib_conf_prefix + '#define @0@ 1\n'.format('HAVE_SYS_XATTR_H')
@@ -64,7 +79,7 @@
if cc.compiles(glib_conf_prefix + '''
#include <stdio.h>
#ifdef HAVE_SYS_TYPES_H
-@@ -1886,9 +1885,11 @@ elif meson.get_cross_property('have_strl
+@@ -1886,9 +1882,11 @@ elif meson.get_cross_property('have_strl
glib_conf.set('HAVE_STRLCPY', 1)
endif
@@ -79,7 +94,7 @@
python_version = python.language_version()
python_version_req = '>=3.4'
-@@ -1897,7 +1898,7 @@ if not python_version.version_compare(py
+@@ -1897,7 +1895,7 @@ if not python_version.version_compare(py
endif
# Determine which user environment-dependent files that we want to install
@@ -88,7 +103,7 @@
have_sh = find_program('sh', required : false).found() # For glib-gettextize
# Some installed tests require a custom environment
-@@ -1906,7 +1907,7 @@ env_program = find_program('env', requir
+@@ -1906,7 +1904,7 @@ env_program = find_program('env', requir
# FIXME: How to detect Solaris? https://github.com/mesonbuild/meson/issues/1578
if host_system == 'sunos'
glib_conf.set('_XOPEN_SOURCE_EXTENDED', 1)
From: "John D. Baker" <jdbaker@consolidated.net>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 09:40:13 -0500 (CDT)
Just for completeness, the error on netbsd-7/sparc is:
[...]
[41/578] Compiling C object 'glib/4430778@@glib-2.0@sha/gatomic.c.o'.
FAILED: glib/4430778@@glib-2.0@sha/gatomic.c.o
gcc -Iglib/4430778@@glib-2.0@sha -Iglib -I../glib -I. -I../ -I/usr/pkg/include -I/usr/include -I/usr/pkg/include/python3.6 -pipe -D_FILE_OFFSET_BITS=64 -std=gnu89 -D_GNU_SOURCE -fno-strict-aliasing -Wall -Wstrict-prototypes -Wunused -Wno-bad-function-cast -Wno-pedantic -Werror=declaration-after-statement -Werror=format=2 -Werror=implicit-function-declaration -Werror=init-self -Werror=missing-include-dirs -Werror=missing-prototypes -Werror=pointer-arith -O2 -D_FORTIFY_SOURCE=2 -fPIC -pthread '-DG_LOG_DOMAIN="GLib"' -DGLIB_COMPILATION -fvisibility=hidden -MD -MQ 'glib/4430778@@glib-2.0@sha/gatomic.c.o' -MF 'glib/4430778@@glib-2.0@sha/gatomic.c.o.d' -o 'glib/4430778@@glib-2.0@sha/gatomic.c.o' -c ../glib/gatomic.c
../glib/gatomic.c:675:2: error: #error G_ATOMIC_LOCK_FREE defined, but incapable of lock-free atomics.
#error G_ATOMIC_LOCK_FREE defined, but incapable of lock-free atomics.
^
[42/578] Compiling C object 'glib/4430778@@glib-2.0@sha/garray.c.o'.
ninja: build stopped: subcommand failed.
*** Error code 1
Stop.
make[1]: stopped in /x/pkgsrc/devel/glib2
*** Error code 1
Stop.
make: stopped in /x/pkgsrc/devel/glib2
--
|/"\ John D. Baker, KN5UKS NetBSD Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net OpenBSD FreeBSD
| X No HTML/proprietary data in email. BSD just sits there and works!
|/ \ GPGkeyID: D703 4A7E 479F 63F8 D3F4 BD99 9572 8F23 E4AD 1645
From: "John D. Baker" <jdbaker@consolidated.net>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/54298: devel/glib2 fails to build
Date: Tue, 25 Jun 2019 17:22:13 -0500 (CDT)
Using the proposed patch recently posted (and copied in private email),
"devel/glib2" now successfully builds on netbsd-7/sparc.
Thanks.
--
|/"\ John D. Baker, KN5UKS NetBSD Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net OpenBSD FreeBSD
| X No HTML/proprietary data in email. BSD just sits there and works!
|/ \ GPGkeyID: D703 4A7E 479F 63F8 D3F4 BD99 9572 8F23 E4AD 1645
From: "Patrick Welche" <prlw1@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/54298 CVS commit: pkgsrc/devel/glib2
Date: Wed, 26 Jun 2019 10:42:50 +0000
Module Name: pkgsrc
Committed By: prlw1
Date: Wed Jun 26 10:42:50 UTC 2019
Modified Files:
pkgsrc/devel/glib2: Makefile distinfo
pkgsrc/devel/glib2/patches: patch-meson.build
Added Files:
pkgsrc/devel/glib2/patches: patch-glib_gatomic.c patch-glib_gatomic.h
Log Message:
g/c use of __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 which glib was already
ignoring for linux and android.
http://mail-index.netbsd.org/tech-userlevel/2019/06/25/msg011965.html
Should complete PR pkg/54298
To generate a diff of this commit:
cvs rdiff -u -r1.255 -r1.256 pkgsrc/devel/glib2/Makefile
cvs rdiff -u -r1.251 -r1.252 pkgsrc/devel/glib2/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/devel/glib2/patches/patch-glib_gatomic.c \
pkgsrc/devel/glib2/patches/patch-glib_gatomic.h
cvs rdiff -u -r1.4 -r1.5 pkgsrc/devel/glib2/patches/patch-meson.build
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: feedback->closed
State-Changed-By: prlw1@NetBSD.org
State-Changed-When: Thu, 01 Aug 2019 15:46:11 +0000
State-Changed-Why:
Finally mentioned upstream:
gsize: https://gitlab.gnome.org/GNOME/glib/issues/1777
gatomic: https://gitlab.gnome.org/GNOME/glib/issues/1856
From: "Patrick Welche" <prlw1@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/54298 CVS commit: pkgsrc/devel/glib2
Date: Fri, 7 Feb 2020 17:05:15 +0000
Module Name: pkgsrc
Committed By: prlw1
Date: Fri Feb 7 17:05:14 UTC 2020
Modified Files:
pkgsrc/devel/glib2: Makefile distinfo
pkgsrc/devel/glib2/patches: patch-meson.build
Removed Files:
pkgsrc/devel/glib2/patches: patch-glib_glibconfig.h.in
patch-glib_gtypes.h
Log Message:
Apply upstream's
Check size_t compatibility with various other types
commit 505c9544247f27cb6ebf749d0902d53c33dac308
which will hopefully fix PR pkg/54909 and not break PR pkg/54298
To generate a diff of this commit:
cvs rdiff -u -r1.266 -r1.267 pkgsrc/devel/glib2/Makefile \
pkgsrc/devel/glib2/distinfo
cvs rdiff -u -r1.1 -r0 pkgsrc/devel/glib2/patches/patch-glib_glibconfig.h.in
cvs rdiff -u -r1.4 -r0 pkgsrc/devel/glib2/patches/patch-glib_gtypes.h
cvs rdiff -u -r1.8 -r1.9 pkgsrc/devel/glib2/patches/patch-meson.build
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.46 2020/01/03 16:35:01 leot Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2020
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.