]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* tests/foreign.at (Libtool): Ignore configure's stderr.
authorAkim Demaille <akim@epita.fr>
Fri, 20 Apr 2001 17:38:22 +0000 (17:38 +0000)
committerAkim Demaille <akim@epita.fr>
Fri, 20 Apr 2001 17:38:22 +0000 (17:38 +0000)
ChangeLog
configure
tests/foreign.at

index 4d3b78fd60864d815cdca28c7658963f90d648d0..9dac53931908684a33f5fd5790aaaf57d1494b81 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2001-04-20  Akim Demaille  <akim@epita.fr>
+
+       * tests/foreign.at (Libtool): Ignore configure's stderr.
+
 2001-04-20  Tim Van Holder  <tim.van.holder@pandora.be>
 
        * acgeneral.m4 (AC_OUTPUT): Close the descriptor before running
index d53fcc5445005fd60006db09345d1812326e0086..013dbaffaed75966060004f28e3fe946429917e0 100755 (executable)
--- a/configure
+++ b/configure
@@ -2074,7 +2074,23 @@ EOF
 chmod +x $CONFIG_STATUS
 ac_clean_files=$ac_clean_files_save
 
-test "$no_create" = yes || $SHELL $CONFIG_STATUS || { (exit 1); exit 1; }
+# configure is writing to config.log, and then calls config.status.
+# config.status does its own redirection, appending to config.log.
+# Unfortunately, on DOS this fails, as config.log is still kept open
+# by configure, so config.status won't be able to write to it; its
+# output is simply discarded.  So we exec the FD to /dev/null,
+# effectively closing config.log, so it can be properly (re)opened and
+# appended to by config.status.  When coming back to configure, we
+# need to make the FD available again.
+if test "$no_create" != yes; then
+  ac_cs_success=:
+  exec 5>/dev/null
+  $SHELL $CONFIG_STATUS || ac_cs_success=false
+  exec 5>>config.log
+  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
+  # would make configure fail if this is the last instruction.
+  $ac_cs_success || { (exit 1); exit 1; }
+fi
 
 # Report the state of this version of Autoconf if this is a beta.
 case 2.49e in
index b509891ce0cb9070f69c50ff546f5cf2374d7142..082b602d92d8cfb91d9e134eaf6170fba9dc5d1b 100644 (file)
@@ -19,6 +19,9 @@ AT_CHECK([[libtoolize --version | egrep '1\.3(\.[0-4])?$' && exit 77]],
 # Using a configure.in, have libtoolize confess where libtool.m4 is.
 AT_DATA([configure.in],
 [[AC_INIT
+# The other tests are relying on Autoconf's own copy of install-sh
+# etc. via AC_CONFIG_AUX_DIR(..).  Don't do that here, since we don't
+# want libtoolize to pollute Autoconf's srcdir.
 AC_CONFIG_AUX_DIR(.)
 AC_PROG_LIBTOOL
 ]])
@@ -31,6 +34,9 @@ AT_CHECK([libtoolize | sed -n ["s,^.*\`\(/[^']*\)'.*,\1,p"]],
 AT_CHECK([grep . stdout], 0, [ignore])
 AT_CHECK([test -f "`cat stdout`"])
 
+# libtoolize installed everything but install-sh...
+touch install-sh
+
 # Build the concatenation of libtool.m4 and configure.ac.
 cp `cat stdout` configure.in
 cat >>configure.in <<_EOF
@@ -42,7 +48,14 @@ _EOF
 
 AT_CHECK_AUTOCONF
 
-touch install-sh
-AT_CHECK_CONFIGURE
+# Ignore stderr, because ltconfig always loads the cache, which is
+# /dev/null, and some shells choke on this.  For instance with Bash
+# 2.05, you get:
+#
+#   loading cache /dev/null within ltconfig
+#   ./ltconfig: .: /dev/null: not a regular file
+#
+# But the script executes properly.
+AT_CHECK_CONFIGURE([], [], [], [ignore])
 
 AT_CLEANUP(install-sh ltconfig libtool at-path ltmain.sh config.guess config.sub)