+2001-01-30 Akim Demaille <akim@epita.fr>
+
+ * tests/compile.at: New test.
+ * tests/atspecific.at (AT_CHECK): When given 77 as expected exit
+ status, don't include the `skip' mechanism.
+
2001-01-30 Akim Demaille <akim@epita.fr>
* tests/base.at (AC_CACHE_CHECK): Typo and clean up.
expout, [$at_diff expout at-stdout >&5 || at_failed=:],
[], [$at_diff empty at-stdout >&5 || at_failed=:],
[echo $at_n "AS_ESCAPE([$3])$at_c" | $at_diff - at-stdout >&5 || at_failed=:])
-dnl Check exit val.
+dnl Check exit val. Don't `skip' if we are precisely checking $? = 77.
case $at_status in
- 77) exit 77;;
+m4_case([$2],
+ [77],
+ [],
+ [ 77) exit 77;;
+])dnl
m4_case([$2],
[ignore],
[ *);;],
expout, [$at_diff expout at-stdout >&5 || at_failed=:],
[], [$at_diff empty at-stdout >&5 || at_failed=:],
[echo $at_n "AS_ESCAPE([$3])$at_c" | $at_diff - at-stdout >&5 || at_failed=:])
-dnl Check exit val.
+dnl Check exit val. Don't `skip' if we are precisely checking $? = 77.
case $at_status in
- 77) exit 77;;
+m4_case([$2],
+ [77],
+ [],
+ [ 77) exit 77;;
+])dnl
m4_case([$2],
[ignore],
[ *);;],
]])
+
+## -------------------------- ##
+## Broken/missing compilers. ##
+## -------------------------- ##
+
+
+# Check that Autoconf correctly diagnoses broken compilers, and in
+# particular, if it does not exit 77, the test suite is in trouble...
+# FIXME: Once a precise message decided, check stderr of configure.
+AT_SETUP([Broken/missing compilers])
+
+AT_DATA([configure.ac],
+[[AC_INIT
+CC=no-such-compiler
+AC_PROG_CC
+]])
+
+AT_CHECK_AUTOCONF
+AT_CHECK_CONFIGURE([], 77)
+
+AT_CLEANUP
+
+
## ------------ ##
## C keywords. ##
## ------------ ##