[PATCH] Handle gcc -std=c99 -D_XOPEN_SOURCE=600 [BZ #284]

Jakub Jelinek jakub@redhat.com
Fri Jul 30 07:58:00 GMT 2004


On Fri, Jul 23, 2004 at 01:19:46PM -0700, Ulrich Drepper wrote:
> Joseph S. Myers wrote:
> 
> > c99 is the name of the compiler to "accept source code conforming to the
> > ISO C standard".  For example,
> 
> And once -D_POSIX_C_SOURCE=200112L is defined all this ISO C nonsense
> must be completely out of the way.  No __STRICT_ANSI__, since non-ISO C
> stuff is used.  The same applies to a few other defines.  Only if none
> is defined can this silly strict ISO C business take place.

I guess it all depends what exact meaning __STRICT_ANSI__ is supposed to have.
Either its definition chooses only ISO C90 (resp. C99) features in the
headers, or it can be combined with other feature set macros with the result
of a union between ISO C90 (resp. C99) features and features selected by
the other feature macros.
The __STRICT_ANSI__ documentation in info gcc doesn't seem to favor either
of these definitions, at least in my reading.

	Jakub



More information about the Libc-hacker mailing list