]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* man/Makefile.am (MOSTLYCLEANFILES): Add $(srcdir)/*.t.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 10 Jun 2005 17:56:21 +0000 (17:56 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 10 Jun 2005 17:56:21 +0000 (17:56 +0000)
(.x.1): Ignore the time stamp in the .TH line when deciding whether
to update the man page.  That way, we don't have to check in new
man pages every month.

ChangeLog
man/Makefile.am

index 37720ad31480ff2da09ea169f1c5c3bad077f1c2..78e181947f4f637f25c49bf741e3df8d3d7668c2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
 
+       * man/Makefile.am (MOSTLYCLEANFILES): Add $(srcdir)/*.t.
+       (.x.1): Ignore the time stamp in the .TH line when deciding whether
+       to update the man page.  That way, we don't have to check in new
+       man pages every month.
+
        * lib/m4sugar/m4sh.m4 (AS_VAR_TEST_SET): Work even if $1 contains
        quotes and backslashes.  Patch from Derek Price.
 
index fe813798ac937657dc701e4d9f8ec352a5ed4caf..e74355d376b0de64086d51d705c4703abafd7eae 100644 (file)
@@ -47,6 +47,10 @@ $(srcdir)/ifnames.1:    $(common_dep) $(binsrcdir)/ifnames.in
 $(srcdir)/config.guess.1: $(top_srcdir)/config/config.guess
 $(srcdir)/config.sub.1:   $(top_srcdir)/config/config.sub
 
+remove_time_stamp = 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/'
+
+MOSTLYCLEANFILES = $(srcdir)/*.t
+
 SUFFIXES = .x .1
 
 .x.1:
@@ -65,4 +69,11 @@ SUFFIXES = .x .1
        $(HELP2MAN) \
            --include=$*.x \
            --include=$(srcdir)/common.x \
-           --output=$@ `echo '$*' | sed 's,.*/,,'`
+           --output=$@.t `echo '$*' | sed 's,.*/,,'`
+       if sed $(remove_time_stamp) $@ >$@a.t 2>/dev/null && \
+          sed $(remove_time_stamp) $@.t | cmp $@a.t - >/dev/null 2>&1; then \
+               touch $@; \
+       else \
+               mv $@.t $@; \
+       fi
+       rm -f $@*.t