* Jan Engelhardt wrote on Wed, Mar 11, 2009 at 10:55:02PM CET: > On Wednesday 2009-03-11 22:43, Ralf Wildenhues wrote: > >The command line option --silent-rules does the same as the argument > >`silent' to the AM_INIT_AUTOMAKE macro in configure.ac: > > AM_INIT_AUTOMAKE([silent]) > > > >Both enable silent mode for all Makefile.in files. > > Hm that's a bit unintuitive. One can run `automake -Wall` from the > command line, and one can put -Wall into AM_INIT_AUTOMAKE(). > One can use --foreign as a CLI argument, and AUTOMAKE_OPTIONS=foreign > (and probably AM_INIT_AUTOMAKE([foreign])). > > But introducing two names for silent/silent-rules, well.. ick.
Agreed. > >The reason that the command line option is not called `--silent' is that > >normally, i.e., with several other GNU software, --silent is the > >opposite of --verbose, and changes the verbosity of the command. But > >--silent-rules does not change the verbosity of the automake command. > > Yeah I thought so. In that case, I would avoid using silent at all > and consistently use silent-rules throughout. Good idea. Pushed. Thanks, Ralf Rename `silent' mode to `silent-rules' mode. * automake.in (define_verbose_var, verbose_flag) (define_verbose_tagvar, handle_options, handle_languages) (handle_configure, parse_arguments): Rename the `silent' option to `silent-rules', so it coincides with the `--silent-rules' command line option; adjust all code and comments. * lib/Automake/Options.pm (_process_option_list): Likewise. * doc/automake.texi (Invoking Automake, Libtool Flags, Options): Likewise. * NEWS: Adjust. * tests/dollarvar.test, tests/silent.test, tests/silent2.test, tests/silent3.test, tests/silent4.test, tests/silent5.test, tests/silent6.test, tests/silent7.test: Likewise. Suggestion by Jan Engelhardt. diff --git a/NEWS b/NEWS index 6975751..885abc0 100644 --- a/NEWS +++ b/NEWS @@ -109,7 +109,7 @@ New in 1.10a: - The `color-tests' option causes colored test result output on terminals. - - The `silent' option enables Linux kernel-style silent build output. + - The `silent-rules' option enables Linux kernel-style silent build output. This option requires the widely supported but non-POSIX `make' feature of recursive variable expansion, so do not use it if your package needs to build with `make' implementations that do not support it. diff --git a/automake.in b/automake.in index 9ee9dfd..cb4d1de 100755 --- a/automake.in +++ b/automake.in @@ -1111,11 +1111,11 @@ sub backname ($) ################################################################ -# Silent mode handling functions. +# `silent-rules' mode handling functions. # verbose_var (NAME) # ------------------ -# The public variable stem used to implement `silent'. +# The public variable stem used to implement `silent-rules'. sub verbose_var ($) { my ($name) = @_; @@ -1124,7 +1124,7 @@ sub verbose_var ($) # verbose_private_var (NAME) # -------------------------- -# The naming policy for the private variables used to implement `silent'. +# The naming policy for the private variables for `silent-rules'. sub verbose_private_var ($) { my ($name) = @_; @@ -1133,13 +1133,13 @@ sub verbose_private_var ($) # define_verbose_var (NAME, VAL) # ------------------------------ -# For `silent' mode, setup VAR and dispatcher, to expand to VAL if silent. +# For `silent-rules' mode, setup VAR and dispatcher, to expand to VAL if silent. sub define_verbose_var ($$) { my ($name, $val) = @_; my $var = verbose_var ($name); my $pvar = verbose_private_var ($name); - if (option 'silent') + if (option 'silent-rules') { # Using `$V' instead of `$(V)' breaks IRIX make. define_variable ($var, '$(' . $pvar . '_$(V))', INTERNAL); @@ -1157,7 +1157,7 @@ sub verbose_flag ($) { my ($name) = @_; return '$(' . verbose_var ($name) . ')' - if (option 'silent'); + if (option 'silent-rules'); return ''; } @@ -1171,11 +1171,11 @@ sub silent_flag () # define_verbose_tagvar (NAME) # ---------------------------- -# Engage the needed `silent' machinery for tag NAME. +# Engage the needed `silent-rules' machinery for tag NAME. sub define_verbose_tagvar ($) { my ($name) = @_; - if (option 'silent') + if (option 'silent-rules') { define_verbose_var ($name, '@echo " '. $name . ' ' x (6 - length ($name)) . '" $@;'); define_verbose_var ('at', '@'); @@ -1184,7 +1184,7 @@ sub define_verbose_tagvar ($) # define_verbose_libtool # ---------------------- -# Engage the needed `silent' machinery for `libtool --silent'. +# Engage the needed `silent-rules' machinery for `libtool --silent'. sub define_verbose_libtool () { define_verbose_var ('lt', '--silent'); @@ -1216,7 +1216,7 @@ sub handle_options # Override portability-recursive warning. switch_warning ('no-portability-recursive') - if option 'silent'; + if option 'silent-rules'; if ($strictness == GNITS) { @@ -1654,7 +1654,7 @@ sub handle_languages define_linker_variable ($languages{'c'}); } - # Always provide the user with `AM_V_GEN' for `silent' mode. + # Always provide the user with `AM_V_GEN' for `silent-rules' mode. define_verbose_tagvar ('GEN'); } @@ -4180,7 +4180,7 @@ sub handle_configure ($$$@) my $automake_options = '--' . (global_option 'cygnus' ? 'cygnus' : $strictness_name) . (global_option 'no-dependencies' ? ' --ignore-deps' : '') - . (global_option 'silent' ? ' --silent-rules' : ''); + . (global_option 'silent-rules' ? ' --silent-rules' : ''); $output_rules .= file_contents ('configure', @@ -8148,7 +8148,8 @@ sub parse_arguments () 'o|output-dir=s' => \$output_directory, 'a|add-missing' => \$add_missing, 'c|copy' => \$copy_missing, - 'silent-rules' => sub { set_global_option ('silent', $cli_where); }, + 'silent-rules' => sub { set_global_option ('silent-rules', + $cli_where); }, 'v|verbose' => sub { setup_channel 'verb', silent => 0; }, 'W|warnings=s' => \&parse_warnings, # These long options (--Werror and --Wno-error) for backward diff --git a/doc/automake.texi b/doc/automake.texi index 2a22ca4..fc072fd 100644 --- a/doc/automake.texi +++ b/doc/automake.texi @@ -2517,7 +2517,7 @@ removed in a future release. @item --silent-rules @opindex --silent-rules -Enable the @option{silent} option globally (@pxref{Options}). +Enable the @option{silent-rules} option globally (@pxref{Options}). @item -v @itemx --verbose @@ -2566,7 +2566,7 @@ variables. The categories output by default are @samp{syntax} and @samp{unsupported}. Additionally, @samp{gnu} and @samp{portability} are enabled in @option{--gnu} and @option{--gnits} strictness. -On the other hand, the @option{silent} options (@pxref{Options}) +On the other hand, the @option{silent-rules} options (@pxref{Options}) turns off portability warnings about recursive variable expansions. @vindex WARNINGS @@ -5268,8 +5268,8 @@ The libtool rules also use a @code{LIBTOOLFLAGS} variable that should not be set in @file{Makefile.am}: this is a user variable (@pxref{Flag Variables Ordering}. It allows users to run @samp{make LIBTOOLFLAGS=--silent}, for instance. Note that the verbosity of -...@command{libtool} can also be influenced with the Automake @option{silent} -option (@pxref{Options}). +...@command{libtool} can also be influenced with the Automake +...@option{silent-rules} option (@pxref{Options}). @node LTLIBOBJS, Libtool Issues, Libtool Flags, A Shared Library @@ -8701,9 +8701,9 @@ non-alpha releases. The second form is @sa...@var{major}.@var{min...@var{alpha}}, where @var{ALPHA} is a letter; it should be omitted for non-alpha releases. -...@item @option{silent} -...@cindex Option, @option{silent} -...@opindex silent +...@item @option{silent-rules} +...@cindex Option, @option{silent-rules} +...@opindex silent-rules Enable silent build rules. This will cause many build rules to output a status line of the form @@ -8727,9 +8727,9 @@ file, to allow the user to override the value for subdirectories as well. The current implementation of this feature relies on a non-POSIX, but in practice rather widely supported @file{Makefile} construct of nested variable expansion @samp{$(@var{var1}$(V))}. Do not use the -...@option{silent} option if your package needs to build with +...@option{silent-rules} option if your package needs to build with @command{make} implementations that do not support it. The -...@option{silent} option turns off warnings about recursive variable +...@option{silent-rules} option turns off warnings about recursive variable expansion, which are in turn enabled by @option{-Wportability} (@pxref{Invoking Automake}). diff --git a/lib/Automake/Options.pm b/lib/Automake/Options.pm index 10fd00f..3890caf 100644 --- a/lib/Automake/Options.pm +++ b/lib/Automake/Options.pm @@ -267,7 +267,7 @@ sub _process_option_list (\%$@) || $_ eq 'no-exeext' || $_ eq 'no-define' || $_ eq 'std-options' || $_ eq 'color-tests' - || $_ eq 'silent' + || $_ eq 'silent-rules' || $_ eq 'cygnus' || $_ eq 'no-dependencies') { # Explicitly recognize these. diff --git a/tests/dollarvar.test b/tests/dollarvar.test index 5b79eb0..8dc54f7 100755 --- a/tests/dollarvar.test +++ b/tests/dollarvar.test @@ -17,7 +17,7 @@ # Test to make sure that -Wportability complains about recursive # variable expansions and variables containing `$', `$(...)', or # `${...}' in the name. We support recursive variable expansions using -# the latter two constructs for the `silent' option, and they are +# the latter two constructs for the `silent-rules' option, and they are # rather widely supported in practice. OTOH variable definitions # containing a `$' on the left hand side of an assignment are not # portable in practice, even though POSIX allows them. :-/ @@ -45,8 +45,8 @@ grep 'Makefile.am:5' stderr grep 'Makefile.am:6' stderr grep 'Makefile.am:7' stderr -# On the other hand, if we allow `silent' mode, then we need to allow -# recursive variable expansion, too. +# On the other hand, if we allow `silent-rules' mode, then we need to +# allow recursive variable expansion, too. # This should work with the `--silent-rules' command line switch. AUTOMAKE_fails -Wportability --silent-rules @@ -58,7 +58,7 @@ grep 'Makefile.am:6' stderr && Exit 1 grep 'Makefile.am:7' stderr && Exit 1 # This should work with AUTOMAKE_OPTIONS. -echo 'AUTOMAKE_OPTIONS = silent' >> Makefile.am +echo 'AUTOMAKE_OPTIONS = silent-rules' >> Makefile.am AUTOMAKE_fails -Wportability grep 'Makefile.am:2' stderr diff --git a/tests/silent.test b/tests/silent.test index b3c03e4..b39d49c 100755 --- a/tests/silent.test +++ b/tests/silent.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check silent mode, without libtool, standard depmode case. +# Check silent-rules mode, without libtool, standard depmode case. # Please keep this file in sync with silent2.test. @@ -32,7 +32,7 @@ AC_OUTPUT EOF cat > Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent +AUTOMAKE_OPTIONS = silent-rules # Need generic and non-generic rules. bin_PROGRAMS = foo bar bar_CFLAGS = $(AM_CFLAGS) @@ -40,7 +40,7 @@ SUBDIRS = sub EOF cat > sub/Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent subdir-objects +AUTOMAKE_OPTIONS = silent-rules subdir-objects # Need generic and non-generic rules. bin_PROGRAMS = baz bla bla_CFLAGS = $(AM_CFLAGS) diff --git a/tests/silent2.test b/tests/silent2.test index 136952e..a1149f4 100755 --- a/tests/silent2.test +++ b/tests/silent2.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check silent mode, without libtool, non-fastdep case +# Check silent-rules mode, without libtool, non-fastdep case # (so that, with GCC, we also cover the other code paths in depend2). # Please keep this file in sync with silent.test. @@ -34,7 +34,7 @@ AC_OUTPUT EOF cat > Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent +AUTOMAKE_OPTIONS = silent-rules # Need generic and non-generic rules. bin_PROGRAMS = foo bar bar_CFLAGS = $(AM_CFLAGS) @@ -42,7 +42,7 @@ SUBDIRS = sub EOF cat > sub/Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent subdir-objects +AUTOMAKE_OPTIONS = silent-rules subdir-objects # Need generic and non-generic rules. bin_PROGRAMS = baz bla bla_CFLAGS = $(AM_CFLAGS) diff --git a/tests/silent3.test b/tests/silent3.test index 0df2bae..5e2ecda 100755 --- a/tests/silent3.test +++ b/tests/silent3.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check silent mode, with libtool, standard depmode case. +# Check silent-rules mode, with libtool, standard depmode case. # Please keep this file in sync with silent4.test. @@ -34,7 +34,7 @@ AC_OUTPUT EOF cat > Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent +AUTOMAKE_OPTIONS = silent-rules # Need generic and non-generic rules. lib_LTLIBRARIES = libfoo.la libbar.la libbar_la_CFLAGS = $(AM_CFLAGS) @@ -42,7 +42,7 @@ SUBDIRS = sub EOF cat > sub/Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent subdir-objects +AUTOMAKE_OPTIONS = silent-rules subdir-objects # Need generic and non-generic rules. lib_LTLIBRARIES = libbaz.la libbla.la libbla_la_CFLAGS = $(AM_CFLAGS) diff --git a/tests/silent4.test b/tests/silent4.test index dc897cb..7ed8922 100755 --- a/tests/silent4.test +++ b/tests/silent4.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check silent mode, with libtool, non-fastdep case +# Check silent-rules mode, with libtool, non-fastdep case # (so that, with GCC, we also cover the other code paths in depend2). # Please keep this file in sync with silent3.test. @@ -35,7 +35,7 @@ AC_OUTPUT EOF cat > Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent +AUTOMAKE_OPTIONS = silent-rules # Need generic and non-generic rules. lib_LTLIBRARIES = libfoo.la libbar.la libbar_la_CFLAGS = $(AM_CFLAGS) @@ -43,7 +43,7 @@ SUBDIRS = sub EOF cat > sub/Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent subdir-objects +AUTOMAKE_OPTIONS = silent-rules subdir-objects # Need generic and non-generic rules. lib_LTLIBRARIES = libbaz.la libbla.la libbla_la_CFLAGS = $(AM_CFLAGS) diff --git a/tests/silent5.test b/tests/silent5.test index 4a2fd5d..90e21b9 100755 --- a/tests/silent5.test +++ b/tests/silent5.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check silent mode, languages other than C. +# Check silent-rules mode, languages other than C. required='g++ gfortran flex bison' . ./defs @@ -35,7 +35,7 @@ AC_OUTPUT EOF cat > Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent +AUTOMAKE_OPTIONS = silent-rules # Need generic and non-generic rules. bin_PROGRAMS = foo bar bar_CFLAGS = $(AM_CFLAGS) @@ -47,7 +47,7 @@ BUILT_SOURCES = foo6.h EOF cat > sub/Makefile.am <<'EOF' -AUTOMAKE_OPTIONS = silent subdir-objects +AUTOMAKE_OPTIONS = silent-rules subdir-objects # Need generic and non-generic rules. bin_PROGRAMS = baz bla bla_CFLAGS = $(AM_CFLAGS) diff --git a/tests/silent6.test b/tests/silent6.test index 103cd34..b0cacc8 100755 --- a/tests/silent6.test +++ b/tests/silent6.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check user extensibility of silent mode. +# Check user extensibility of silent-rules mode. . ./defs @@ -89,7 +89,7 @@ grep ' --silent-rules' Makefile.in $AUTOMAKE --force -Wno-all -Wportability --silent-rules grep ' --silent-rules' Makefile.in -echo 'AUTOMAKE_OPTIONS = silent' >> Makefile.am +echo 'AUTOMAKE_OPTIONS = silent-rules' >> Makefile.am $AUTOMAKE --force grep 'AM_V_GEN' Makefile.in $AUTOMAKE --force -Wno-all -Wportability diff --git a/tests/silent7.test b/tests/silent7.test index 4fd52f3..68a0e89 100755 --- a/tests/silent7.test +++ b/tests/silent7.test @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. -# Check user extensibility of silent mode. +# Check user extensibility of silent-rules mode. . ./defs @@ -51,7 +51,7 @@ grep 'echo ' stdout $MAKE distclean -echo 'AUTOMAKE_OPTIONS = silent' >> Makefile.am +echo 'AUTOMAKE_OPTIONS = silent-rules' >> Makefile.am $AUTOMAKE ./configure