delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2001/11/21/13:11:48

Date: Wed, 21 Nov 2001 20:10:11 +0200
From: "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il>
Sender: halo1 AT zahav DOT net DOT il
To: Andris Pavenis <pavenis AT lanet DOT lv>
Message-Id: <4331-Wed21Nov2001201010+0200-eliz@is.elta.co.il>
X-Mailer: emacs 21.1.50 (via feedmail 8 I) and Blat ver 1.8.9
CC: djgpp-workers AT delorie DOT com
In-reply-to: <Pine.A41.4.05.10111211832360.95704-100000@ieva06> (message from
Andris Pavenis on Wed, 21 Nov 2001 18:42:03 +0200 (WET))
Subject: Re: GCC option -ansi and libstdc++-v3
References: <Pine DOT A41 DOT 4 DOT 05 DOT 10111211832360 DOT 95704-100000 AT ieva06>
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> Date: Wed, 21 Nov 2001 18:42:03 +0200 (WET)
> From: Andris Pavenis <pavenis AT lanet DOT lv>
> 
> gcc -ansi defines __STRICT_ANSI__ which hides prototypes for some
> function needed by libstdc++-v3. Here are some examples one 
> can find quickly:
> 	lrand48()  (recent report today about compilation errors)
> 	strtoll() and strtoull() are also used 
> 	maybe some others
> They are detected at configure time without specifying -ansi.
> So option -ansi may screw compilation of C++ sources. The same
> about defining __POSIX_SOURCE__

I don't see the problem: similar trouble happens if someone compiles
with -ansi a C program which uses non-standard functions.  The only
difference is that in C++ a missing prototype is an error, not a
warning.

Don't other C libraries have the same problem?

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019