This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: c++/5845: Seemingly correct code gets "syntax error", but only on gcc 3.0
- From: rodrigc at gcc dot gnu dot org
- To: gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, rodrigc at gcc dot gnu dot org, stanisls at ifi dot uio dot no
- Date: 6 Mar 2002 02:06:07 -0000
- Subject: Re: c++/5845: Seemingly correct code gets "syntax error", but only on gcc 3.0
- Reply-to: rodrigc at gcc dot gnu dot org, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, rodrigc at gcc dot gnu dot org, stanisls at ifi dot uio dot no, gcc-gnats at gcc dot gnu dot org
Synopsis: Seemingly correct code gets "syntax error", but only on gcc 3.0
State-Changed-From-To: open->feedback
State-Changed-By: rodrigc
State-Changed-When: Tue Mar 5 18:06:06 2002
State-Changed-Why:
There is a bug in the configure script for Common C++.
http://cplusplus.sourceforge.net
During the configure, it does not detect the
<exception> header file:
configure:5784: checking for exception
configure:5794: gcc -E conftest.c >/dev/null 2>conftest.out
configure:5790:21: exception: No such file or directory
configure: failed program was:
#line 5789 "configure"
#include "confdefs.h"
#include <exception>
Basically the problem is in configure.in:
AC_CHECK_HEADERS(sys/file.h syslog.h posix_evlog.h exception ss.h)
What happens is, the configure script creates
a header file with these two lines:
#include "confdefs.h"
#include <exception>
and then calls:
gcc -E
on that file.
The C compiler doesn't know where the C++ headers are,
so the test fails.
Can you tell the Common C++ people to improve their
autoconf test?
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=5845