This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Fixed build failure on Linux in cppfiles (_XOPEN_SOURCE is evil)
> From: Andreas Jaeger <aj@suse.de>
> Date: 18 Sep 2000 09:40:00 +0200
> >>>>> Geoff Keating writes:
>
> Geoff> This seems harmless but unnecessary. Does anyone know any non-glibc
> Geoff> system that does _anything_ different based on whether _GNU_SOURCE is
> Geoff> defined?
>
> Geoff, please read the whole thread. Mark and Alexandre suggested to
> use _GNU_SOURCE only on a glibc based system to be on the save side.
> For now I do think that any non-glibc systems just ignores
> _GNU_SOURCE.
I have been following the thread closely. I just don't see why
(effectively)
#if defined(__GLIBC)
#define _GNU_SOURCE
#endif
is better than a plain
#define _GNU_SOURCE
since you're using macros in the implementation namespace both ways.
> I don't have a problem with the current state either - both ways
> work.
I don't mind either. Feel free to commit the patch if you like it.
--
- Geoffrey Keating <geoffk@cygnus.com>