public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c++/4915: Solaris: C++ compiler defines _XOPEN_SOURCE
@ 2001-11-15 12:43 dpo
0 siblings, 0 replies; 2+ messages in thread
From: dpo @ 2001-11-15 12:43 UTC (permalink / raw)
To: gcc-gnats
>Number: 4915
>Category: c++
>Synopsis: Solaris: C++ compiler defines _XOPEN_SOURCE
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Nov 20 12:36:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator: Dimitri Papadopoulos
>Release: 3.0.2
>Organization:
>Environment:
Solaris 8 on various Sparc machines
>Description:
The C++ compiler defines the macro variable _XOPEN_SOURCE
to be 500 while the C compiler does not:
$ gcc --version
3.0.2
$ cat foo.c
_XOPEN_SOURCE
$ gcc -E foo.c
# 1 "foo.c"
_XOPEN_SOURCE
$
$ g++ --version
3.0.2
$ cat foo.cc
_XOPEN_SOURCE
$ g++ -E foo.cc
# 1 "foo.cc"
500
$
There's no reason why the C++ compiler should override the
default Solaris compiling environment, is there? One should
be able to decide whether to define _XOPEN_SOURCE or not.
For reference here is the output of the Sun compilers:
$ cc -E foo.c
# 1 "foo.c"
_XOPEN_SOURCE
#ident "acomp: WorkShop Compilers 5.0 99/12/04 C 5.0 patch 107289-05"
$
$ CC -E foo.cc
#1 "foo.cc"
_XOPEN_SOURCE
$
>How-To-Repeat:
>Fix:
Do not define _POSIX_SOURCE in the C++ compiler.
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: c++/4915: Solaris: C++ compiler defines _XOPEN_SOURCE
@ 2002-03-02 19:03 rodrigc
0 siblings, 0 replies; 2+ messages in thread
From: rodrigc @ 2002-03-02 19:03 UTC (permalink / raw)
To: dpo, gcc-bugs, gcc-prs, nobody
Synopsis: Solaris: C++ compiler defines _XOPEN_SOURCE
State-Changed-From-To: open->closed
State-Changed-By: rodrigc
State-Changed-When: Sat Mar 2 19:03:46 2002
State-Changed-Why:
See:
http://gcc.gnu.org/ml/gcc/2002-02/msg01368.html
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=4915
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-03-03 3:03 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-11-15 12:43 c++/4915: Solaris: C++ compiler defines _XOPEN_SOURCE dpo
2002-03-02 19:03 rodrigc
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).