Protect against multiple inclusion.
[gnulib.git] / m4 / Makefile.in
index 17c2551..831cadc 100644 (file)
@@ -4,16 +4,11 @@
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
-
 # This program is distributed in the hope that it will be useful,
 # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
 # PARTICULAR PURPOSE.
 
-# Generate this list with
-# find . -type f -name '*.m4' -printf '%f\n'|sort |fmt |tr '\012' @ \
-#   |sed 's/@$/%/;s/@/ \\@/g' |tr @% '\012\012'
-
 
 SHELL = /bin/sh
 
@@ -94,12 +89,14 @@ VERSION = @VERSION@
 YACC = @YACC@
 l = @l@
 
-EXTRA_DIST = README \
-isc-posix.m4 \
-assert.m4 check-decl.m4 chown.m4 const.m4 d-ino.m4 d-type.m4 decl.m4 error.m4 \
-getgroups.m4 getline.m4 getloadavg.m4 inttypes_h.m4 jm-mktime.m4 jm-winsz1.m4 \
-jm-winsz2.m4 lfs.m4 lstat.m4 malloc.m4 memcmp.m4 perl.m4 prereq.m4 putenv.m4 \
-readdir.m4 realloc.m4 ssize_t.m4 stat.m4 strftime.m4 uintmax_t.m4 uptime.m4
+EXTRA_DIST = README Makefile.am.in assert.m4 check-decl.m4 check-type.m4 \
+chown.m4 const.m4 d-ino.m4 d-type.m4 decl.m4 error.m4 fnmatch.m4 \
+fstypename.m4 getgroups.m4 getline.m4 getloadavg.m4 gettext.m4 glibc.m4 \
+inttypes_h.m4 isc-posix.m4 jm-glibc-io.m4 jm-macros.m4 jm-mktime.m4 \
+jm-winsz1.m4 jm-winsz2.m4 lchown.m4 lcmessage.m4 lfs.m4 ls-mntd-fs.m4 \
+lstat.m4 malloc.m4 memcmp.m4 perl.m4 prereq.m4 progtest.m4 putenv.m4 \
+readdir.m4 realloc.m4 regex.m4 st_dm_mode.m4 st_mtim.m4 stat.m4 \
+strftime.m4 uintmax_t.m4 uptime.m4 utimbuf.m4 utime.m4 utimes.m4
 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
 CONFIG_HEADER = ../config.h
 CONFIG_CLEAN_FILES = 
@@ -192,6 +189,18 @@ clean-generic maintainer-clean-generic clean mostlyclean distclean \
 maintainer-clean
 
 
+Makefile.am: Makefile.am.in
+       rm -f $@ $@t
+       sed -n '1,/^##m4-files-begin/p' $< > $@t
+       ( echo EXTRA_DIST = README Makefile.am.in; \
+         find . -type f -name '*.m4' -print |sed 's,^\./,,' |sort ) \
+           |fmt | (tr '\012' @; echo) \
+           |sed 's/@$$/%/;s/@/ \\@/g' |tr @% '\012\012' \
+         >> $@t
+       sed -n '/^##m4-files-end/,$$p' $< >> $@t
+       chmod a-w $@t
+       mv $@t $@
+
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT: