diff options
-rwxr-xr-x | bootstrap | 51 | ||||
-rw-r--r-- | doc/Makefile.am | 8 | ||||
-rw-r--r-- | pies/Makefile.am | 4 |
3 files changed, 39 insertions, 24 deletions
@@ -430,21 +430,29 @@ silent_rules_prog=' # state = 1 - first line inside a rule # state = 2 - subsequent lines inside a rule # cont = 1 - this line is a continuation of the previous one - +# defn = 1 - insert AM_V_GEN/AM_V_at definitions after the initail comment # Print comment lines /^[ \t]*#/ { print; next } +# Insert AM_V_ definitions, if required. +state == 0 && defn == 1 { + print "AM_DEFAULT_VERBOSITY=0" # FIXME + print "AM_V_GEN = $(am__v_GEN_$(V))" + print "am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))" + print "am__v_GEN_0 = @echo \" GEN \" $@;" + print "AM_V_at = $(am__v_at_$(V))" + print "am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))" + print "am__v_at_0 = @" + defn = 0 +} # Start of a rule /^[^ \t].*:/ { print; state = 1; cont = 0; next } # First action within the rule state == 1 && /^\t/ { # Print silent rules without changes. The second match # is necessary to handle @VAR@ substitutions. - if (match($1, /^@/) && !match($1, /@$/)) - print - else { - sub(/^\t[\t ]*/,"") - print "\t$(AM_V_GEN)" $0 - } + if (!(match($1, /^@/) && !match($1, /.@$/))) + sub(/^\t[\t ]*/, "&$(AM_V_GEN)") + print cont = match($0, /\\$/) state = 2 next @@ -452,22 +460,32 @@ state == 1 && /^\t/ { # All non-continuation lines within the rule are prefixed # with $(AM_V_at). state == 2 && /^\t/ && NF > 0 { - if (!cont) { - sub(/^\t[\t ]*/,"") - print "\t$(AM_V_at)" $0 - } else - print + if (!cont) + sub(/^\t[\t ]*/, "&$(AM_V_at)") + print cont = match($0, /\\$/) next } # Everything else is output verbatim -{ print }' +{ print } +' silent_rules=yes grep 'AM_SILENT_RULES' configure.ac > /dev/null || grep '^[ ]*AM_INIT_AUTOMAKE([^)][^)]*silent-rules' configure.ac > /dev/null || silent_rules=no +silentize() { + if test "$silent_rules" = yes; then + case $1 in + *.am) defn=0;; + *.in) defn=1;; + esac + awk -v defn=$defn "$silent_rules_prog" $1 > ${1}-t && + mv ${1}-t $1 + fi +} + slurp() { for dir in . `(cd $1 && find * -type d -print)`; do copied= @@ -489,10 +507,7 @@ slurp() { rm -f $dir/$gnulib_mk && sed "$remove_intl" $1/$dir/$file >$dir/$gnulib_mk } - if test "$silent_rules" = yes; then - awk "$silent_rules_prog" $dir/$gnulib_mk > $dir/${gnulib_mk}-t && - mv $dir/${gnulib_mk}-t $dir/${gnulib_mk} - fi + silentize $dir/$gnulib_mk elif { test "${2+set}" = set && test -r $2/$dir/$file; } || version_controlled_file $dir $file; then echo "$0: $dir/$file overrides $1/$dir/$file" @@ -651,7 +666,7 @@ if test $with_gettext = yes; then '"$XGETTEXT_OPTIONS"' $${end_of_xgettext_options+} } ' po/Makevars.template >po/Makevars - + silentize po/Makefile.in.in if test -d runtime-po; then # Similarly for runtime-po/Makevars, but not quite the same. rm -f runtime-po/Makevars diff --git a/doc/Makefile.am b/doc/Makefile.am index c10bb0b..1a7396c 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -35,7 +35,7 @@ EXTRA_DIST = \ untabify.el clean-local: - rm -rf manual + @rm -rf manual # Checking check-format: @@ -141,15 +141,15 @@ check-unrevised: all-check-docs: check-format check-options check-pragmas check-builtins check-mflib check-exceptions check-refs check-fixmes check-writeme check-unrevised check-docs: - $(MAKE) -k all-check-docs + @$(MAKE) -k all-check-docs # master-menu: - emacs -batch -l mastermenu.el -f make-master-menu $(info_TEXINFOS) + $(AM_V_GEN)emacs -batch -l mastermenu.el -f make-master-menu $(info_TEXINFOS) untabify: - emacs -batch -l untabify.el $(info_TEXINFOS) $(mailfromd_TEXINFOS) + @emacs -batch -l untabify.el $(info_TEXINFOS) $(mailfromd_TEXINFOS) final: untabify master-menu diff --git a/pies/Makefile.am b/pies/Makefile.am index 1902804..7aaf759 100644 --- a/pies/Makefile.am +++ b/pies/Makefile.am @@ -1,5 +1,5 @@ # This file is part of mailfrom filter. -# Copyright (C) 2008 Sergey Poznyakoff +# Copyright (C) 2008, 2009 Sergey Poznyakoff # # 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 @@ -34,7 +34,7 @@ EXTRA_DIST = pies.rcin noinst_DATA = pies.rc DISTCLEANFILES = pies.rc .rcin.rc: - sed 's|SBINDIR|$(sbindir)|g' $< > $@ + $(AM_V_GEN)sed 's|SBINDIR|$(sbindir)|g' $< > $@ meta1lex.c: meta1gram.h |