From: Paul Eggert Date: Sat, 15 Apr 2006 01:13:32 +0000 (+0000) Subject: * lib/autoconf/general.m4 (_AC_INIT_CONFIG_LOG): Close X-Git-Tag: AUTOCONF-2.59d~124 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5455100eda81a8eedbb137015b2e2955ea625a33;p=thirdparty%2Fautoconf.git * lib/autoconf/general.m4 (_AC_INIT_CONFIG_LOG): Close AS_MESSAGE_LOG_FD before reopening it onto the log file. This works around a MinGW bug reported by Eric Paire. Make sure that all writes to the log file append to it, rather than possibly losing data. * lib/autotest/general.m4 (AT_INIT): Likewise. --- diff --git a/ChangeLog b/ChangeLog index e5f98c090..17087c86b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2006-04-14 Paul Eggert + + * lib/autoconf/general.m4 (_AC_INIT_CONFIG_LOG): Close + AS_MESSAGE_LOG_FD before reopening it onto the log file. + This works around a MinGW bug reported by Eric Paire. + Make sure that all writes to the log file append to it, + rather than possibly losing data. + * lib/autotest/general.m4 (AT_INIT): Likewise. + 2006-04-14 Stepan Kasal * lib/Autom4te/FileUtils.pm (find_file): Fix a typo in the diff --git a/lib/autoconf/general.m4 b/lib/autoconf/general.m4 index 2429425d2..265f2c60b 100644 --- a/lib/autoconf/general.m4 +++ b/lib/autoconf/general.m4 @@ -1103,8 +1103,8 @@ fi])dnl m4_define([_AC_INIT_CONFIG_LOG], [m4_divert_text([INIT_PREPARE], [m4_define([AS_MESSAGE_LOG_FD], 5)dnl -exec AS_MESSAGE_LOG_FD>config.log -cat >&AS_MESSAGE_LOG_FD <<_ACEOF +exec AS_MESSAGE_LOG_FD>&- # Work around a MinGW bug. +cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. @@ -1115,6 +1115,7 @@ generated by m4_PACKAGE_STRING. Invocation command line was $ $[0] $[@] _ACEOF +exec AS_MESSAGE_LOG_FD>>config.log AS_UNAME >&AS_MESSAGE_LOG_FD cat >&AS_MESSAGE_LOG_FD <<_ACEOF diff --git a/lib/autotest/general.m4 b/lib/autotest/general.m4 index 6ba3d005e..d5b4b361f 100644 --- a/lib/autotest/general.m4 +++ b/lib/autotest/general.m4 @@ -598,8 +598,13 @@ export PATH # Setting up the FDs. # 5 is the log file. Not to be overwritten if `-d'. m4_define([AS_MESSAGE_LOG_FD], [5]) -$at_debug_p && at_suite_log=/dev/null -exec AS_MESSAGE_LOG_FD>"$at_suite_log" +if $at_debug_p; then + at_suite_log=/dev/null +else + exec AS_MESSAGE_LOG_FD>&- # Work around a MinGW bug. + : >"$at_suite_log" +fi +exec AS_MESSAGE_LOG_FD>>"$at_suite_log" # Banners and logs. AS_BOX(m4_defn([AT_TESTSUITE_NAME])[.])