+2001-04-04 Lars J. Aas <larsa@sim.no>
+
+ * acgeneral (_AC_INIT_CONFIG_LOG): New macro for setting up the
+ config.log file.
+ (_AC_INIT_DEFAULTS_FDS): Log to /dev/null instead of config.log.
+ (AC_INIT): Invoke _AC_INIT_CONFIG_LOG after _AC_INIT_VERSION.
+
2001-04-04 Lars J. Aas <larsa@sim.no>
* acgeneral.m4 (_AC_INIT_DEFAULTS): Produce better version
# 2 errors and warnings
@%:@ AS_MESSAGE_LOG_FD compiler messages saved in config.log
@%:@ AS_MESSAGE_FD checking for... messages and results
-exec AS_MESSAGE_LOG_FD>>config.log
+exec AS_MESSAGE_LOG_FD>>/dev/null
exec AS_MESSAGE_FD>&1
])# _AC_INIT_DEFAULTS_FDS
# so uname gets run too.
ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-cat >config.log <<EOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by m4_ifset([AC_PACKAGE_NAME],
- [AC_PACKAGE_NAME ])dnl
-$as_me[]m4_ifset([AC_PACKAGE_VERSION],
- [ AC_PACKAGE_VERSION]), which was
-generated by GNU Autoconf AC_ACVERSION. Invocation command line was
-
- $ $[0] $[@]
-
-EOF
-AS_UNAME >>config.log
-
-cat >>config.log <<EOF
-## ------------ ##
-## Core tests. ##
-## ------------ ##
-
-EOF
_AC_INIT_DEFAULTS_FDS
#
])# _AC_INIT_VERSION
+# _AC_INIT_CONFIG_LOG
+# -------------------
+# Initialize the config.log file descriptor and write header to it.
+m4_define([_AC_INIT_CONFIG_LOG],
+[m4_divert_text([INIT_PREPARE],
+[exec AS_MESSAGE_LOG_FD>>config.log
+cat >config.log <<EOF
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+
+It was created by m4_ifset([AC_PACKAGE_NAME],
+ [AC_PACKAGE_NAME ])dnl
+$as_me[]m4_ifset([AC_PACKAGE_VERSION],
+ [ AC_PACKAGE_VERSION]), which was
+generated by GNU Autoconf AC_ACVERSION. Invocation command line was
+
+ $ $[0] $[@]
+
+EOF
+AS_UNAME >>config.log
+
+cat >>config.log <<EOF
+## ------------ ##
+## Core tests. ##
+## ------------ ##
+
+EOF
+])])# _AC_INIT_CONFIG_LOG
+
# _AC_INIT_PREPARE_FS_SEPARATORS
# ------------------------------
# Compute the directory and path separators.
_AC_INIT_SRCDIR
_AC_INIT_HELP
_AC_INIT_VERSION
+_AC_INIT_CONFIG_LOG
_AC_INIT_PREPARE
dnl _AC_INIT_COPYRIGHT must be called after _AC_INIT_VERSION, since
dnl it dumps into a diversion prepared by _AC_INIT_VERSION.
# 2 errors and warnings
@%:@ AS_MESSAGE_LOG_FD compiler messages saved in config.log
@%:@ AS_MESSAGE_FD checking for... messages and results
-exec AS_MESSAGE_LOG_FD>>config.log
+exec AS_MESSAGE_LOG_FD>>/dev/null
exec AS_MESSAGE_FD>&1
])# _AC_INIT_DEFAULTS_FDS
# so uname gets run too.
ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-cat >config.log <<EOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by m4_ifset([AC_PACKAGE_NAME],
- [AC_PACKAGE_NAME ])dnl
-$as_me[]m4_ifset([AC_PACKAGE_VERSION],
- [ AC_PACKAGE_VERSION]), which was
-generated by GNU Autoconf AC_ACVERSION. Invocation command line was
-
- $ $[0] $[@]
-
-EOF
-AS_UNAME >>config.log
-
-cat >>config.log <<EOF
-## ------------ ##
-## Core tests. ##
-## ------------ ##
-
-EOF
_AC_INIT_DEFAULTS_FDS
#
])# _AC_INIT_VERSION
+# _AC_INIT_CONFIG_LOG
+# -------------------
+# Initialize the config.log file descriptor and write header to it.
+m4_define([_AC_INIT_CONFIG_LOG],
+[m4_divert_text([INIT_PREPARE],
+[exec AS_MESSAGE_LOG_FD>>config.log
+cat >config.log <<EOF
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+
+It was created by m4_ifset([AC_PACKAGE_NAME],
+ [AC_PACKAGE_NAME ])dnl
+$as_me[]m4_ifset([AC_PACKAGE_VERSION],
+ [ AC_PACKAGE_VERSION]), which was
+generated by GNU Autoconf AC_ACVERSION. Invocation command line was
+
+ $ $[0] $[@]
+
+EOF
+AS_UNAME >>config.log
+
+cat >>config.log <<EOF
+## ------------ ##
+## Core tests. ##
+## ------------ ##
+
+EOF
+])])# _AC_INIT_CONFIG_LOG
+
# _AC_INIT_PREPARE_FS_SEPARATORS
# ------------------------------
# Compute the directory and path separators.
_AC_INIT_SRCDIR
_AC_INIT_HELP
_AC_INIT_VERSION
+_AC_INIT_CONFIG_LOG
_AC_INIT_PREPARE
dnl _AC_INIT_COPYRIGHT must be called after _AC_INIT_VERSION, since
dnl it dumps into a diversion prepared by _AC_INIT_VERSION.