From 70b577f2dff10268ad5ad952a267b4b370a2c124 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sun, 10 Jan 1999 18:12:43 +0000 Subject: [PATCH] 1999-01-10 Tom Tromey * remake-hdr.am: Provide `else' clause for each `if'. 1999-01-10 Alexandre Oliva * remake-hdr.am: recover from removal of config headers, and try to get real timestamps, which is useful for CVS files --- ChangeLog | 9 +++++++++ lib/am/remake-hdr.am | 22 +++++++++++++++++----- remake-hdr.am | 22 +++++++++++++++++----- 3 files changed, 43 insertions(+), 10 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3dd773ab..1d679a3c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +1999-01-10 Tom Tromey + + * remake-hdr.am: Provide `else' clause for each `if'. + +1999-01-10 Alexandre Oliva + + * remake-hdr.am: recover from removal of config headers, and try + to get real timestamps, which is useful for CVS files + 1999-01-10 Tom Tromey * automake.in (handle_merge_targets): Don't special-case "-local" diff --git a/lib/am/remake-hdr.am b/lib/am/remake-hdr.am index 9161aea1..d6a144e6 100644 --- a/lib/am/remake-hdr.am +++ b/lib/am/remake-hdr.am @@ -1,5 +1,5 @@ ## automake - create Makefile.in from Makefile.am -## Copyright (C) 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc. +## Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -16,16 +16,28 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. @CONFIG_HEADER@: @STAMP@ -## Rules without a rule work funny. So supply a dummy rule. - @: +## Recover from removal of CONFIG_HEADER + @if test ! -f $@; then \ + rm -f @STAMP@; \ + $(MAKE) @STAMP@; \ + else :; fi ## Explicitly look in srcdir for benefit of non-GNU makes. @STAMP@: $(srcdir)/@CONFIG_HEADER_IN@ $(top_builddir)/config.status cd $(top_builddir) \ && CONFIG_FILES= CONFIG_HEADERS=@CONFIG_HEADER_FULL@ \ $(SHELL) ./config.status - @echo timestamp > @STAMP@ +## Try to get a real timestamp; this is useful for CVS + @(date || ls -l @CONFIG_HEADER@ || echo timestamp) \ + > @STAMP@ 2> /dev/null ## Explicitly look in srcdir for benefit of non-GNU makes. $(srcdir)/@CONFIG_HEADER_IN@: @MAINTAINER_MODE_TRUE@$(srcdir)/@STAMP@.in +## Recover from removal of CONFIG_HEADER_IN + @if test ! -f $@; then \ + rm -f $(srcdir)/@STAMP@.in; \ + $(MAKE) $(srcdir)/@STAMP@.in; \ + else :; fi $(srcdir)/@STAMP@.in: $(top_srcdir)/configure.in $(ACLOCAL_M4) @FILES@ cd $(top_srcdir) && $(AUTOHEADER) - @echo timestamp > $(srcdir)/@STAMP@.in +## Try to get a real timestamp; this is useful for CVS + @(date || ls -l $(srcdir)/@CONFIG_HEADER_IN@ || echo timestamp) \ + > $(srcdir)/@STAMP@.in 2> /dev/null diff --git a/remake-hdr.am b/remake-hdr.am index 9161aea1..d6a144e6 100644 --- a/remake-hdr.am +++ b/remake-hdr.am @@ -1,5 +1,5 @@ ## automake - create Makefile.in from Makefile.am -## Copyright (C) 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc. +## Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999 Free Software Foundation, Inc. ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -16,16 +16,28 @@ ## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA ## 02111-1307, USA. @CONFIG_HEADER@: @STAMP@ -## Rules without a rule work funny. So supply a dummy rule. - @: +## Recover from removal of CONFIG_HEADER + @if test ! -f $@; then \ + rm -f @STAMP@; \ + $(MAKE) @STAMP@; \ + else :; fi ## Explicitly look in srcdir for benefit of non-GNU makes. @STAMP@: $(srcdir)/@CONFIG_HEADER_IN@ $(top_builddir)/config.status cd $(top_builddir) \ && CONFIG_FILES= CONFIG_HEADERS=@CONFIG_HEADER_FULL@ \ $(SHELL) ./config.status - @echo timestamp > @STAMP@ +## Try to get a real timestamp; this is useful for CVS + @(date || ls -l @CONFIG_HEADER@ || echo timestamp) \ + > @STAMP@ 2> /dev/null ## Explicitly look in srcdir for benefit of non-GNU makes. $(srcdir)/@CONFIG_HEADER_IN@: @MAINTAINER_MODE_TRUE@$(srcdir)/@STAMP@.in +## Recover from removal of CONFIG_HEADER_IN + @if test ! -f $@; then \ + rm -f $(srcdir)/@STAMP@.in; \ + $(MAKE) $(srcdir)/@STAMP@.in; \ + else :; fi $(srcdir)/@STAMP@.in: $(top_srcdir)/configure.in $(ACLOCAL_M4) @FILES@ cd $(top_srcdir) && $(AUTOHEADER) - @echo timestamp > $(srcdir)/@STAMP@.in +## Try to get a real timestamp; this is useful for CVS + @(date || ls -l $(srcdir)/@CONFIG_HEADER_IN@ || echo timestamp) \ + > $(srcdir)/@STAMP@.in 2> /dev/null -- 2.43.5