]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
Wrote AM_CONFIG_HEADER
authorTom Tromey <tromey@redhat.com>
Fri, 22 Nov 1996 06:25:29 +0000 (06:25 +0000)
committerTom Tromey <tromey@redhat.com>
Fri, 22 Nov 1996 06:25:29 +0000 (06:25 +0000)
ChangeLog
TODO
automake.in
m4/Makefile.am
m4/Makefile.in
m4/header.m4 [new file with mode: 0644]
tests/ChangeLog
tests/confsub.test

index c308367b1ac2969e9b5602340a3f0bd3bb63a3f6..662f62d3f25de72bb035287da13af916a3db9059 100644 (file)
--- 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 6648a4fd95b68f3a35feff5cb1a2a044b21559b5..342af9706132803f99023dc234b46fd73d46ea80 100644 (file)
--- 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
 
index a44747d8bc70bdaf5ca38c1c3dc7a2da5d8da252..e20c2312fda0d6f657a11149c8000f20ff3e2d2b 100755 (executable)
@@ -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;
index 5b98da3212dc780e16d8bac4baaded8a387a6343..b7ccb6661e07065b1942ca3787612124a9f77fdb 100644 (file)
@@ -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)
index be5c6ef9c77c9c008a8f889f846981dde03b5a14..e06cdaf0db90b7bc1a331a2983721d93a690cf25 100644 (file)
@@ -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 (file)
index 0000000..0477b3a
--- /dev/null
@@ -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([,])])
index 7bd06d35218931b274349806641a41da4fba5ec9..08305c46dd89cf5724bc22faa31d70e64b02ae8a 100644 (file)
@@ -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.
index 295ce04c28274ab701865c1bfad595084f258293..faa6d6e8d43327e8dea87a65e085209c260552f1 100755 (executable)
@@ -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