From 689e8e64ed2287d4cb7a87c0fd25567e905cbe03 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 11 Mar 2015 17:25:01 +0100 Subject: build: Add silent rules for substitutions. * substitute.am (AM_V_SUBSTITUTE, AM_V_SUBSTITUTE_, AM_V_SUBSTITUTE_0): New variables. * doc/man/Makefile.am (.in): Use $(AM_V_SUBSTITUTE). * doc/user/Makefile.am (lout/front-page.lout): Likewise. * src/Makefile.am (.in): Likewise. * src/guile/Makefile.am (.in.scm): Likewise. * emacs/Makefile.am (.in): Likewise. --- doc/man/Makefile.am | 2 +- doc/user/Makefile.am | 2 +- emacs/Makefile.am | 2 +- src/Makefile.am | 2 +- src/guile/Makefile.am | 7 ++++--- substitute.am | 4 ++++ 6 files changed, 12 insertions(+), 7 deletions(-) diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am index 1156944..cb9f017 100644 --- a/doc/man/Makefile.am +++ b/doc/man/Makefile.am @@ -7,5 +7,5 @@ CLEANFILES = $(man1_MANS) include $(top_srcdir)/substitute.am .in: - $(substitute) "$^" > "$@.tmp" && \ + $(AM_V_SUBSTITUTE)$(substitute) "$^" > "$@.tmp" && \ mv "$@.tmp" "$@" diff --git a/doc/user/Makefile.am b/doc/user/Makefile.am index b72cfde..c813c42 100644 --- a/doc/user/Makefile.am +++ b/doc/user/Makefile.am @@ -122,7 +122,7 @@ include $(top_srcdir)/substitute.am lout/front-page.lout: lout/front-page.lout.in test -d "lout" || mkdir "lout" - $(substitute) "$^" > "$@.tmp" && \ + $(AM_V_SUBSTITUTE)$(substitute) "$^" > "$@.tmp" && \ mv "$@.tmp" "$@" endif HAVE_LOUT diff --git a/emacs/Makefile.am b/emacs/Makefile.am index 85084df..8afd259 100644 --- a/emacs/Makefile.am +++ b/emacs/Makefile.am @@ -6,5 +6,5 @@ CLEANFILES = $(lisp_DATA) include $(top_srcdir)/substitute.am .in: - $(substitute) "$^" > "$@.tmp" && \ + $(AM_V_SUBSTITUTE)$(substitute) "$^" > "$@.tmp" && \ mv "$@.tmp" "$@" diff --git a/src/Makefile.am b/src/Makefile.am index e423791..5a620dd 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -10,6 +10,6 @@ CLEANFILES = $(bin_SCRIPTS) $(noinst_SCRIPTS) include $(top_srcdir)/substitute.am .in: - $(substitute) "$^" > "$@.tmp" && \ + $(AM_V_SUBSTITUTE)$(substitute) "$^" > "$@.tmp" && \ chmod +x "$@.tmp" && \ mv "$@.tmp" "$@" diff --git a/src/guile/Makefile.am b/src/guile/Makefile.am index ea5df96..e4dd75c 100644 --- a/src/guile/Makefile.am +++ b/src/guile/Makefile.am @@ -1,4 +1,5 @@ -# Copyright 2005, 2006, 2007, 2008, 2009, 2010, 2012 Ludovic Courtès +# Copyright 2005, 2006, 2007, 2008, 2009, 2010, 2012, +# 2015 Ludovic Courtès # # This file is part of Skribilo. # @@ -108,8 +109,8 @@ BUILT_SOURCES = \ skribilo/utils/images.scm .in.scm: - $(MKDIR_P) "`dirname $@`" - $(substitute) "$^" > "$@.tmp" && \ + $(AM_V_SUBSTITUTE)$(MKDIR_P) "`dirname $@`" ; \ + $(substitute) "$^" > "$@.tmp" && \ mv "$@.tmp" "$@" #all-local: diff --git a/substitute.am b/substitute.am index 9623b7e..80953bc 100644 --- a/substitute.am +++ b/substitute.am @@ -1,5 +1,9 @@ # Automake/Autoconf substitutions. +AM_V_SUBSTITUTE = $(AM_V_SUBSTITUTE_$(V)) +AM_V_SUBSTITUTE_ = $(AM_V_SUBSTITUTE_$(AM_DEFAULT_VERBOSITY)) +AM_V_SUBSTITUTE_0 = @echo " SUBSTITUTE" $@; + substitute = sed -e 's,[@]guilemoduledir[@],$(guilemoduledir),g' \ -e 's,[@]abs_top_srcdir[@],$(abs_top_srcdir),g' \ -e 's,[@]abs_top_builddir[@],$(abs_top_builddir),g' \ -- cgit v1.2.3