Gentoo Archives: gentoo-musl

From: Lei Zhang <zhanglei.april@×××××.com>
To: Luca Barbato <lu_zero@g.o>
Cc: gentoo-musl@l.g.o
Subject: Re: [gentoo-musl] [GSoC] _GNU_SOURCE in C++
Date: Tue, 14 Jun 2016 09:35:20
Message-Id: CAOYuCc1JqdQg3eshzPvTYjo-8jHP0Z_NW+e6P2G2OT5gyQGW1w@mail.gmail.com
1 2016-06-14 17:28 GMT+08:00 Luca Barbato <lu_zero@g.o>:
2 > On 14/06/16 11:17, Lei Zhang wrote:
3 >> 2016-06-14 17:12 GMT+08:00 Luca Barbato <lu_zero@g.o>:
4 >>> On 14/06/16 10:28, Lei Zhang wrote:
5 >>>> 2016-06-14 16:10 GMT+08:00 Felix Janda <felix.janda@××××××.de>:
6 >>>>> Take a look at the discussion at
7 >>>>>
8 >>>>> http://www.openwall.com/lists/musl/2014/04/15/3
9 >>>>
10 >>>> And some view from the LLVM side:
11 >>>>
12 >>>> http://article.gmane.org/gmane.comp.compilers.clang.devel/46390
13 >>>>
14 >>>> IMHO, the real problem is the abuse of _GNU_SOURCE by C++ compiler.
15 >>>> The decisions made by LLVM and musl both look reasonable to me.
16 >>>>
17 >>>
18 >>> -U_GNU_SOURCE would make you get through the problem for the time being?
19 >>>
20 >>> Given you aren't using libstdc++ in that case, assuming libcxx does not
21 >>> have the need probably might be the easiest workaround.
22 >>
23 >> Unfortunately libc++ depends on this macro as well:
24 >>
25 >> http://lists.llvm.org/pipermail/cfe-dev/2016-June/049447.html
26 >>
27 >> I'm imagining some ugly hacks on LLVM now...
28 >>
29 >
30 > Please try to prepare a list and blog about this problem since possibly
31 > needs additional awareness.
32 >
33 > If the symbols needed aren't GNU-only there are other macros to expose
34 > them (and the llvm people just went the lazy route to get them).
35
36 I agree. It seems libstdc++ is also taking the lazy route, and someone
37 intended to fix it:
38
39 https://lwn.net/Articles/590504/
40
41 but I see no progress so far.
42
43
44 Lei