Re: Targets using implicit extern "C"

2005-05-10 Thread Mark Mitchell
Joe Buck wrote: Right, but you don't need the answer to the question until it's time to build libstdc++, and you can't build libstdc++ without a C library. So can't the test be deferred until that point? I don't think that's a good idea. People build compilers without headers frequently, and this

Re: Targets using implicit extern "C"

2005-05-10 Thread E. Weddington
Joe Buck wrote: Ian Lance Taylor wrote: It would be hard to make that completely reliable for embedded systems development, where the header files may or not be available in any standard place at the time that gcc is configured. On Tue, May 10, 2005 at 04:30:43PM -0600, E. Weddington wrot

Re: Targets using implicit extern "C"

2005-05-10 Thread Joe Buck
> Joe Buck <[EMAIL PROTECTED]> writes: > >>I think that the decision should be made at configure time, by checking > >>the #include headers to see if they are C++-ready. Look for the string > >>"__cplusplus" in some set of standard headers, if it is not found, > >>assume that we'll need implici

Re: Targets using implicit extern "C"

2005-05-10 Thread E. Weddington
Ian Lance Taylor wrote: Joe Buck <[EMAIL PROTECTED]> writes: On Tue, May 10, 2005 at 02:26:12PM -0400, Ian Lance Taylor wrote: How would people feel about adding a configure option --with-implicit-extern-c? Then we could justifiably flip the default for the generic *-elf, etc., targets. I

Re: Targets using implicit extern "C"

2005-05-10 Thread Ian Lance Taylor
Joe Buck <[EMAIL PROTECTED]> writes: > On Tue, May 10, 2005 at 02:26:12PM -0400, Ian Lance Taylor wrote: > > How would people feel about adding a configure option > > --with-implicit-extern-c? Then we could justifiably flip the default > > for the generic *-elf, etc., targets. In fact in general

Re: Targets using implicit extern "C"

2005-05-10 Thread Stan Shebs
Joe Buck wrote: On Tue, May 10, 2005 at 02:26:12PM -0400, Ian Lance Taylor wrote: How would people feel about adding a configure option --with-implicit-extern-c? Then we could justifiably flip the default for the generic *-elf, etc., targets. In fact in general we could then take the macro out of

Re: Targets using implicit extern "C"

2005-05-10 Thread Joe Buck
On Tue, May 10, 2005 at 02:26:12PM -0400, Ian Lance Taylor wrote: > How would people feel about adding a configure option > --with-implicit-extern-c? Then we could justifiably flip the default > for the generic *-elf, etc., targets. In fact in general we could > then take the macro out of the tm.

Re: Targets using implicit extern "C"

2005-05-10 Thread Ian Lance Taylor
"Joseph S. Myers" <[EMAIL PROTECTED]> writes: > In particular, I'm surprised at the Darwin configurations apparently > not defining NO_IMPLICIT_EXTERN_C, and at most OpenBSD configurations > not doing so (but alpha-openbsd gets it from alpha/alpha.h); VxWorks > configurations are also inconsistent

RE: Targets using implicit extern "C"

2005-05-09 Thread Dave Korn
Original Message >From: Ralf Corsepius >Sent: 09 May 2005 09:27 > On Sun, 2005-05-08 at 22:54 -0700, Zack Weinberg wrote: >> Ralf Corsepius <[EMAIL PROTECTED]> writes: >> >>> On Sun, 2005-05-08 at 21:34 -0700, Zack Weinberg wrote: Ralf Corsepius <[EMAIL PROTECTED]> writes:

Re: Targets using implicit extern "C"

2005-05-09 Thread Joseph S. Myers
On Mon, 9 May 2005, Ralf Corsepius wrote: > FWIW: IMO, NO_IMPLICIT_EXTERN_C actually is an OS/libc feature ("Your > system headers are c++ aware"), therefore it is hardly possible or > useful to ever use "#define NO_IMPLICIT_EXTERN_C" on "generic" targets > (*-elf, *-coff etc.). You could apply t

Re: Targets using implicit extern "C"

2005-05-09 Thread Ralf Corsepius
On Sun, 2005-05-08 at 22:54 -0700, Zack Weinberg wrote: > Ralf Corsepius <[EMAIL PROTECTED]> writes: > > > On Sun, 2005-05-08 at 21:34 -0700, Zack Weinberg wrote: > >> Ralf Corsepius <[EMAIL PROTECTED]> writes: > >> > >> > FWIW: IMO, NO_IMPLICIT_EXTERN_C actually is an OS/libc feature ("Your > >>

Re: Targets using implicit extern "C"

2005-05-08 Thread Zack Weinberg
Ralf Corsepius <[EMAIL PROTECTED]> writes: > On Sun, 2005-05-08 at 21:34 -0700, Zack Weinberg wrote: >> Ralf Corsepius <[EMAIL PROTECTED]> writes: >> >> > FWIW: IMO, NO_IMPLICIT_EXTERN_C actually is an OS/libc feature ("Your >> > system headers are c++ aware"), therefore it is hardly possible or

Re: Targets using implicit extern "C"

2005-05-08 Thread Ralf Corsepius
On Sun, 2005-05-08 at 21:34 -0700, Zack Weinberg wrote: > Ralf Corsepius <[EMAIL PROTECTED]> writes: > > > FWIW: IMO, NO_IMPLICIT_EXTERN_C actually is an OS/libc feature ("Your > > system headers are c++ aware"), therefore it is hardly possible or > > useful to ever use "#define NO_IMPLICIT_EXTERN

Re: Targets using implicit extern "C"

2005-05-08 Thread Zack Weinberg
Ralf Corsepius <[EMAIL PROTECTED]> writes: > FWIW: IMO, NO_IMPLICIT_EXTERN_C actually is an OS/libc feature ("Your > system headers are c++ aware"), therefore it is hardly possible or > useful to ever use "#define NO_IMPLICIT_EXTERN_C" on "generic" targets > (*-elf, *-coff etc.). I'm going to ask

Re: Targets using implicit extern "C"

2005-05-08 Thread Ralf Corsepius
On Sun, 2005-05-08 at 23:34 +, Joseph S. Myers wrote: > The following targets (based on wildcarded entries from config.gcc) do > *not* appear to define NO_IMPLICIT_EXTERN_C, i.e. GCC is configured to > suppose their headers are not C++-aware and to add an implicit extern > "C" around them. Are

Re: Targets using implicit extern "C"

2005-05-08 Thread David Edelsohn
> Joseph S Myers writes: Joseph> Are there any in this list which should not be, Joseph> i.e. which should be presumed to have C++-aware headers? Conversely, Joseph> are there any in this list whose maintainers can confirm that the Joseph> headers are not C++-aware and so the current configur

Re: Targets using implicit extern "C"

2005-05-08 Thread Andrew Pinski
On May 8, 2005, at 7:34 PM, Joseph S. Myers wrote: In particular, I'm surprised at the Darwin configurations apparently not defining NO_IMPLICIT_EXTERN_C, and at most OpenBSD configurations not doing so (but alpha-openbsd gets it from alpha/alpha.h); VxWorks configurations are also inconsistent in