automake-ng
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Automake-NG] [PATCH 09/12] [ng] cleanup: minor cleanups in remake-hdr.a


From: Stefano Lattarini
Subject: [Automake-NG] [PATCH 09/12] [ng] cleanup: minor cleanups in remake-hdr.am
Date: Mon, 21 May 2012 09:36:26 +0200

* lib/am/remake-hdr.am: Remove an obsolete comment, and a workaround
only needed for parallel BSD make.  Rewrite the recipe of '%CONFIG_H%'
to be less verbose (with no semantic change intended).  Add an
explicative comment.  Remove extra blank lines.

Signed-off-by: Stefano Lattarini <address@hidden>
---
 lib/am/remake-hdr.am |   15 +++++----------
 1 file changed, 5 insertions(+), 10 deletions(-)

diff --git a/lib/am/remake-hdr.am b/lib/am/remake-hdr.am
index a3b54a8..61e32be 100644
--- a/lib/am/remake-hdr.am
+++ b/lib/am/remake-hdr.am
@@ -14,26 +14,21 @@
 ## You should have received a copy of the GNU General Public License
 ## along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-## Explicitly look in srcdir for benefit of non-GNU makes.
-
-
 %CONFIG_H%: %STAMP%
-## Recover from removal of CONFIG_HEADER
-       @if test ! -f $@; then rm -f %STAMP%; else :; fi
-       @if test ! -f $@; then $(MAKE) %STAMP%; else :; fi
-
+## Recover from removal of CONFIG_HEADER.  Break up in two invocations
+## so that "make -n" is properly honored.
+       @test -f $@ || rm -f %STAMP%
+       @test -f $@ || $(MAKE) %STAMP%
 
 %STAMP%: %CONFIG_H_DEPS% $(top_builddir)/config.status
        @rm -f %STAMP%
        cd $(top_builddir) && $(SHELL) ./config.status %CONFIG_H_PATH%
 
-
 ## Only the first file of AC_CONFIG_HEADERS is assumed to be generated
 ## by autoheader.
 if %?FIRST%
 %CONFIG_HIN%: %MAINTAINER-MODE% $(am__configure_deps)
-## Cater to parallel BSD make.
-       ($(am__cd) $(top_srcdir) && $(AUTOHEADER))
+       $(am__cd) $(top_srcdir) && $(AUTOHEADER)
 ## Whenever $(AUTOHEADER) has run, we must make sure that
 ## ./config.status will rebuild config.h.  The dependency from %STAMP%
 ## on %CONFIG_H_DEPS% (which contains config.hin) is not enough to
-- 
1.7.9.5




reply via email to

[Prev in Thread] Current Thread [Next in Thread]