summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>1996-11-22 06:25:29 +0000
committerTom Tromey <tromey@redhat.com>1996-11-22 06:25:29 +0000
commitb67f2a261bd05bf1effd863360de354016e0d4dd (patch)
tree9b6bd449a88116e5d36f543b544f1b9475dfe3b1
parent41018bc35c7d9fc5dd762b6709423e00fb4184cc (diff)
downloadautomake-b67f2a261bd05bf1effd863360de354016e0d4dd.tar.gz
Wrote AM_CONFIG_HEADER
-rw-r--r--ChangeLog6
-rw-r--r--TODO2
-rwxr-xr-xautomake.in8
-rw-r--r--m4/Makefile.am2
-rw-r--r--m4/Makefile.in2
-rw-r--r--m4/header.m412
-rw-r--r--tests/ChangeLog4
-rwxr-xr-xtests/confsub.test2
8 files changed, 33 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index c308367b1..662f62d3f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Thu Nov 21 22:29:30 1996 Tom Tromey <tromey@cygnus.com>
+
+ * m4/header.m4: New file.
+
+ * automake.in (scan_configure): Recognize AM_CONFIG_HEADER.
+
Wed Nov 20 00:23:42 1996 Tom Tromey <tromey@cygnus.com>
* acinstall: Allow commentary at end of "serial" line. From Gord
diff --git a/TODO b/TODO
index 6648a4fd9..342af9706 100644
--- a/TODO
+++ b/TODO
@@ -344,6 +344,8 @@ include Greg Woods' more sophisticated "cvs-dist" target.
document rebuilding configure. CONFIGURE_DEPENDENCIES
+_DEPENDENCIES -vs- _LIBADD/_LDADD; the tradeoffs
+
-- must document all variables that are supposed
to be public knowledge
diff --git a/automake.in b/automake.in
index a44747d8b..e20c2312f 100755
--- a/automake.in
+++ b/automake.in
@@ -3111,10 +3111,14 @@ sub scan_configure
}
# Handle configuration headers.
- if (/AC_CONFIG_HEADER\s*\((.*)\)/)
+ if (/A([CM])_CONFIG_HEADER\s*\((.*)\)/)
{
+ &am_conf_line_error
+ ($., "use \`AM_CONFIG_HEADER', not \`AC_CONFIG_HEADER'")
+ if $1 eq 'C';
+
$config_header_line = $.;
- $config_name = $1;
+ $config_name = $2;
if ($config_name =~ /^([^:]+):(.+)$/)
{
$config_name = $1;
diff --git a/m4/Makefile.am b/m4/Makefile.am
index 5b98da321..b7ccb6661 100644
--- a/m4/Makefile.am
+++ b/m4/Makefile.am
@@ -6,7 +6,7 @@ MAINT_CHARSET = latin1
m4datadir = $(datadir)/aclocal
m4data_DATA = ccstdc.m4 dmalloc.m4 init.m4 install.m4 \
lispdir.m4 maintainer.m4 protos.m4 ptrdiff.m4 regex.m4 strtod.m4 termios.m4 \
-winsz.m4 mktime.m4 error.m4 obstack.m4 sanity.m4
+winsz.m4 mktime.m4 error.m4 obstack.m4 sanity.m4 header.m4
EXTRA_DIST = $(m4data_DATA)
diff --git a/m4/Makefile.in b/m4/Makefile.in
index be5c6ef9c..e06cdaf0d 100644
--- a/m4/Makefile.in
+++ b/m4/Makefile.in
@@ -45,7 +45,7 @@ MAINT_CHARSET = latin1
m4datadir = $(datadir)/aclocal
m4data_DATA = ccstdc.m4 dmalloc.m4 init.m4 install.m4 \
lispdir.m4 maintainer.m4 protos.m4 ptrdiff.m4 regex.m4 strtod.m4 termios.m4 \
-winsz.m4 mktime.m4 error.m4 obstack.m4 sanity.m4
+winsz.m4 mktime.m4 error.m4 obstack.m4 sanity.m4 header.m4
EXTRA_DIST = $(m4data_DATA)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff --git a/m4/header.m4 b/m4/header.m4
new file mode 100644
index 000000000..0477b3a6c
--- /dev/null
+++ b/m4/header.m4
@@ -0,0 +1,12 @@
+# Like AC_CONFIG_HEADER, but automatically create stamp file.
+
+AC_DEFUN(AM_CONFIG_HEADER,
+[AC_PREREQ([2.11.2])
+AC_CONFIG_HEADER($1)
+dnl When config.status generates a header, we must update the stamp-h file.
+dnl This file resides in the same directory as the config header
+dnl that is generated. We must strip everything past the first ":",
+dnl and everything past the last "/".
+changequote(<<,>>)
+AC_OUTPUT_COMMANDS(<<test -z "<<$>>CONFIG_HEADER" || echo timestamp > patsubst($1, <<^\([^:]*/\)?.*>>, <<\1>>)>>)
+changequote([,])])
diff --git a/tests/ChangeLog b/tests/ChangeLog
index 7bd06d352..08305c46d 100644
--- a/tests/ChangeLog
+++ b/tests/ChangeLog
@@ -1,3 +1,7 @@
+Thu Nov 21 22:51:35 1996 Tom Tromey <tromey@cygnus.com>
+
+ * confsub.test: Use AM_CONFIG_HEADER.
+
Tue Nov 19 23:37:32 1996 Tom Tromey <tromey@cygnus.com>
* confvar2.test: New file.
diff --git a/tests/confsub.test b/tests/confsub.test
index 295ce04c2..faa6d6e8d 100755
--- a/tests/confsub.test
+++ b/tests/confsub.test
@@ -6,7 +6,7 @@
cat > configure.in << 'END'
AC_PROG_MAKE_SET
-AC_CONFIG_HEADER(subdir/config.h)
+AM_CONFIG_HEADER(subdir/config.h)
PACKAGE=nonesuch
VERSION=nonesuch
AC_PROG_CC