Hi, Paul Eggert <[EMAIL PROTECTED]> writes:
>> Date: Fri, 05 Jul 2002 10:40:17 -0500 >> From: "Walter E. Brown" <[EMAIL PROTECTED]> >> >> Thanks, Paul, for the courteous and quick response. >> >> Suppose my program defines entities whose names clash with names >> declared in <stdlib.h>. > > That's certainly reasonable, but we're not talking about your actual > program here. We're talking about what the little test program -- the > one that "configure" compiles. Surely this little test program can be > written so that it will still work as desired even if <stdlib.h> is > included. Yep. The program itself will/should never see 'confdefs.h', which should be deleted once 'configure' is done. Also, any fragment in 'configure.in' is basically testing for portability (and/or lack of portability :-) -- so it must be quite tolerant (or quite intolerant so that problems are found quickly). >> However, there may be compelling reasons for autoconf's current >> behavior > > If you find them out, please let me know. Like I said, I don't use > C++, so I'm not the right guy to ask. It would be helpful if this > stuff were written down as comments in the source. I guess the loop in _AC_PROG_CXX_EXIT_DECLARATION for ac_declaration in \ ''\ '#include <stdlib.h>' \ 'extern "C" void std::exit (int) throw (); using std::exit;' \ 'extern "C" void std::exit (int); using std::exit;' \ 'extern "C" void exit (int) throw ();' \ 'extern "C" void exit (int);' \ 'void exit (int);' could use one more alternative: '#include <cstdlib> using std::exit;' before the '#include <stdlib.h>' line. This whole section is necessary since AC_LANG_PROGRAM supports the use of exit() in C/C++ program test fragments. - Hari -- Raja R Harinath ------------------------------ [EMAIL PROTECTED]
