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 Paul Eggert <eggert@cs.ucla.edu>
+
+ * 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 <kasal@ucw.cz>
* lib/Autom4te/FileUtils.pm (find_file): Fix a typo in the
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.
$ $[0] $[@]
_ACEOF
+exec AS_MESSAGE_LOG_FD>>config.log
AS_UNAME >&AS_MESSAGE_LOG_FD
cat >&AS_MESSAGE_LOG_FD <<_ACEOF
# 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])[.])