public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* unneeded -D_GNU_SOURCE
@ 2007-10-23 11:37 Peter S. Mazinger
  2007-10-23 12:52 ` Daniel Jacobowitz
  0 siblings, 1 reply; 2+ messages in thread
From: Peter S. Mazinger @ 2007-10-23 11:37 UTC (permalink / raw)
  To: binutils

Hello,

I have cross-compiled binutils (2.18) in an environment, where though 
glibc headers are used, but _GNU_SOURCE is undefined in features.h 
immediately after it defines _XOPEN_SOURCE/_POSIX_SOURCE and the others 
(the target library does not provide any of the GNU extensions either) and 
found that binutils does not need any of the GNU extensions (meaning those
guarded by __USE_GNU), haven't tracked down which are enough of all those 
defines, but _XOPEN_SOURCE and/or _POSIX_SOURCE could be more appropiate 
to reflect the reality.

Peter

-- 
Peter S. Mazinger <ps dot m at gmx dot net>           ID: 0xA5F059F2
Key fingerprint = 92A4 31E1 56BC 3D5A 2D08  BB6E C389 975E A5F0 59F2

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: unneeded -D_GNU_SOURCE
  2007-10-23 11:37 unneeded -D_GNU_SOURCE Peter S. Mazinger
@ 2007-10-23 12:52 ` Daniel Jacobowitz
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Jacobowitz @ 2007-10-23 12:52 UTC (permalink / raw)
  To: Peter S. Mazinger; +Cc: binutils

On Tue, Oct 23, 2007 at 09:26:27AM +0200, Peter S. Mazinger wrote:
> Hello,
> 
> I have cross-compiled binutils (2.18) in an environment, where though 
> glibc headers are used, but _GNU_SOURCE is undefined in features.h 
> immediately after it defines _XOPEN_SOURCE/_POSIX_SOURCE and the others 
> (the target library does not provide any of the GNU extensions either) and 
> found that binutils does not need any of the GNU extensions (meaning those
> guarded by __USE_GNU), haven't tracked down which are enough of all those 
> defines, but _XOPEN_SOURCE and/or _POSIX_SOURCE could be more appropiate 
> to reflect the reality.

Binutils is written portably.  It isn't supposed to and does not
require _GNU_SOURCE.  But it does detect some GNU extensions in
configure and use them if they are available (e.g. stpcpy).

-- 
Daniel Jacobowitz
CodeSourcery

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-10-23 11:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-10-23 11:37 unneeded -D_GNU_SOURCE Peter S. Mazinger
2007-10-23 12:52 ` Daniel Jacobowitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).