]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Have `make check' succeed with CC=g++.
authorAkim Demaille <akim@epita.fr>
Tue, 11 Apr 2000 12:07:45 +0000 (12:07 +0000)
committerAkim Demaille <akim@epita.fr>
Tue, 11 Apr 2000 12:07:45 +0000 (12:07 +0000)
* tests/atspecific.m4 (AT_TEST_MACRO): Don't check `env-after' if
the file does not exist, which may happen when a `configure' exits
brutally.
* tests/semantics.m4 (AC_CHECK_MEMBERS, AC_CHECK_TYPES): ANSI C++
forbids members named like their hosting struct, so don't do it.

ChangeLog
tests/atspecific.m4
tests/semantics.m4

index 5a3f1cd185a5762883b0778f9e9c9fe6b69e5114..7265a1e0690f3ef8e66cae66a22469116a311fb7 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2000-04-11  Akim Demaille  <akim@epita.fr>
+
+       Have `make check' succeed with CC=g++.
+
+       * tests/atspecific.m4 (AT_TEST_MACRO): Don't check `env-after' if
+       the file does not exist, which may happen when a `configure' exits
+       brutally.
+       * tests/semantics.m4 (AC_CHECK_MEMBERS, AC_CHECK_TYPES): ANSI C++
+       forbids members named like their hosting struct, so don't do it.
+
 2000-04-11  Akim Demaille  <akim@epita.fr>
 
        * autoscan.pl: Reindent using 2 spaces, not 4.
index c783efbab103ebe22828b63c898b825dbc0f9b7f..a09d540b8cd03a89410bc7b6cdc68fb637c00664 100644 (file)
@@ -102,7 +102,12 @@ AT_CHECK([../autoconf -m .. -l $at_srcdir], 0,, ignore)
 AT_CHECK([../autoheader -m .. -l $at_srcdir], 0,, ignore)
 AT_CHECK([top_srcdir=$top_srcdir ./configure], 0, ignore, ignore)
 test -n "$at_verbose" && echo "--- config.log" && cat config.log
-AT_CHECK([cat env-after], 0, expout)
+
+dnl Some tests might exit prematurely when they find a problem, in
+dnl which case `env-after is probably missing.  Don't check it then.
+if test -f env-after; then
+  AT_CHECK([cat env-after], 0, expout)
+fi
 $3
 AT_CLEANUP(configure config.status config.log config.cache config.hin config.h env-after)dnl
 ])dnl AT_TEST_MACRO
index 5919761f3fbc8268003688bc217e989b32cdb656..ce6c2aead8563e0288e4c68b26a734ff560e6b2f 100644 (file)
@@ -19,7 +19,7 @@ AC_TRY_LINK_FUNC(Be_doomed_if_your_libc_has_a_function_named_like_this,
 # ------------
 # Well, I can't imagine a system where `cos' is neither in libc, nor
 # in libm.  Nor can I imagine a lib more likely to exists than libm.
-# But there are system without libm, on which we don't want to have
+# But there are systems without libm, on which we don't want to have
 # this test fail, so exit successfully if `cos' is in libc.
 AT_TEST_MACRO(AC_CHECK_LIB,
 [AC_TRY_LINK_FUNC(cos, exit 0)
@@ -68,23 +68,19 @@ AT_TEST_MACRO(AC_CHECK_HEADERS,
 # AC_CHECK_MEMBERS
 # ----------------
 # Check that it performs the correct actions.
-# Must define HAVE_STRUCT_YES_YES, but not HAVE_STRUCT_YES_NO.
+# Must define HAVE_STRUCT_YES_S_YES, but not HAVE_STRUCT_YES_S_NO.
 AT_TEST_MACRO(AC_CHECK_MEMBERS,
-[AC_CHECK_MEMBERS((struct yes.yes, struct yes.no),,,
-                  [struct yes { int yes ;} ;])],
+[AC_CHECK_MEMBERS((struct yes_s.yes, struct yes_s.no),,,
+                  [struct yes_s { int yes ;} ;])],
 [AT_CHECK_DEFINES(
-[/* #undef HAVE_STRUCT_YES_NO */
-#define HAVE_STRUCT_YES_YES 1
+[/* #undef HAVE_STRUCT_YES_S_NO */
+#define HAVE_STRUCT_YES_S_YES 1
 ])])
 
 
 
 # AC_CHECK_SIZEOF
-# --------------
-# Check that it performs the correct actions.
-# Must define HAVE_STRUCT_YES, HAVE_INT, but not HAVE_STRUCT_NO.
-# `int' and `struct yes' are both checked to test both the compiler
-# builtin types, and defined types.
+# ---------------
 AT_TEST_MACRO(AC_CHECK_SIZEOF,
 [AC_CHECK_SIZEOF(char)
 AC_CHECK_SIZEOF(charchar,,
@@ -104,19 +100,20 @@ typedef struct
 # AC_CHECK_TYPES
 # --------------
 # Check that it performs the correct actions.
-# Must define HAVE_STRUCT_YES, HAVE_INT, but not HAVE_STRUCT_NO.
-# `int' and `struct yes' are both checked to test both the compiler
+# Must define HAVE_STRUCT_YES_S, HAVE_INT, but not HAVE_STRUCT_NO_S.
+# `int' and `struct yes_s' are both checked to test both the compiler
 # builtin types, and defined types.
 AT_TEST_MACRO(AC_CHECK_TYPES,
-[AC_CHECK_TYPES((int, struct yes, struct no),,,
-                [struct yes { int yes ;} ;])],
+[AC_CHECK_TYPES((int, struct yes_s, struct no_s),,,
+                [struct yes_s { int yes ;} ;])],
 [AT_CHECK_DEFINES(
 [#define HAVE_INT 1
-/* #undef HAVE_STRUCT_NO */
-#define HAVE_STRUCT_YES 1
+/* #undef HAVE_STRUCT_NO_S */
+#define HAVE_STRUCT_YES_S 1
 ])])
 
 
+
 # AC_CHECK_TYPES
 # --------------
 # Check that we properly dispatch properly to the old implementation