autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Tru64 cc fails to fail upon bad define


From: Ralf Wildenhues
Subject: Tru64 cc fails to fail upon bad define
Date: Sat, 19 Jun 2010 17:50:32 +0200
User-agent: Mutt/1.5.20 (2010-04-22)

On Tru64/OSF 5.1D, the vendor compiler preprocessor doesn't choke upon a
bad macro name, leading to a testsuite failure:

250. compile.at:292: testing Order of user actions and cleanup ...
../../autoconf/tests/compile.at:328: autoconf --force
../../autoconf/tests/compile.at:329: ./configure $configure_options -q
stdout:
../../autoconf/tests/compile.at:329: exit code was 1, expected 0
config.log:
> This file contains any messages produced by compilers while
> running configure, to aid debugging if configure makes a mistake.
>
> It was created by configure, which was
> generated by GNU Autoconf 2.65.92-f90f2.  Invocation command line was
[...]
> configure:2789: cc -E  conftest.c
> cc: Warning: conftest.c, line 9: "#define" directive is not followed by an ide
ntifier and is being ignored. (badmacroname)
> #define 12 34
> --------^
> configure:2789: $? = 0

I can't get the preprocessor to fail with borked #define or unfinished
'#if' lines, but an unclosed comment works.  OK to commit?

Thanks,
Ralf

    Fix testsuite failure with Tru64 preprocessor.
    
    * tests/compile.at (Order of user actions and cleanup):
    Use incomplete comment rather than bad #define to provoke
    failure with Tru64/OSF 5.1 cc preprocessor.

diff --git a/tests/compile.at b/tests/compile.at
index 129f3c6..346eb65 100644
--- a/tests/compile.at
+++ b/tests/compile.at
@@ -297,7 +297,7 @@ AC_PROG_CC
 AC_PREPROC_IFELSE([AC_LANG_PROGRAM([int ok;], [])],
                  [test -f conftest.err || AS_EXIT([1])],
                  [AS_EXIT([1])])
-AC_PREPROC_IFELSE([AC_LANG_PROGRAM([#define 12 34], [])],
+AC_PREPROC_IFELSE([AC_LANG_PROGRAM([/*], [])],
                  [AS_EXIT([1])],
                  [test -f conftest.err || AS_EXIT([1])])
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]