From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 16 07:28:46 2012 Received: (at submit) by debbugs.gnu.org; 16 Apr 2012 11:28:46 +0000 Received: from localhost ([127.0.0.1]:36452 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SJk6v-0003RS-5i for submit@debbugs.gnu.org; Mon, 16 Apr 2012 07:28:46 -0400 Received: from eggs.gnu.org ([208.118.235.92]:57745) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SJk6s-0003RG-Lm for submit@debbugs.gnu.org; Mon, 16 Apr 2012 07:28:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SJk6f-0000S2-Vi for submit@debbugs.gnu.org; Mon, 16 Apr 2012 07:28:35 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:41776) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SJk6f-0000Ru-Pe for submit@debbugs.gnu.org; Mon, 16 Apr 2012 07:28:29 -0400 Received: from eggs.gnu.org ([208.118.235.92]:56624) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SJk6Z-0001iw-IU for bug-automake@gnu.org; Mon, 16 Apr 2012 07:28:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SJk6T-0000LD-Am for bug-automake@gnu.org; Mon, 16 Apr 2012 07:28:22 -0400 Received: from mail-bk0-f41.google.com ([209.85.214.41]:50630) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SJk6L-0000Fv-J3; Mon, 16 Apr 2012 07:28:09 -0400 Received: by bkwq16 with SMTP id q16so4518151bkw.0 for ; Mon, 16 Apr 2012 04:28:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:mime-version:to:cc:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=wCj81GyAxBf6wsIDKtySwh6CVkojv9efABrq0XB3te4=; b=XG4LTXt3YQQxVS3AVdoMsNgmybYGDcdgeWL0gxIAQuYVO2dLPmj1Vk2hmcultB5Qt0 rJEetxrqbd7pPISu6hyjgrvqp29bz6HVs+nA/QQcg+7OrIl0EqiMMc95JE8HzrB1oErg 9EmnAGoe2Pu8q3L77NgdFKx5GnHnbfOWYDMnRs9ZFWGw4YqvmWPX26JRlaMMUnVUFEVw TJL/y6SbT0aHGImaAEwHWHGDUhV+CX1cvSbe7TdPFudU4P8b1o9Le6sBRRzNeBHNEiU4 SwBmN33/tm0s6DL6JeyehypLPij3B9iLj1SbDi+bOf+jY1Y0JZTTel6CmRRfG+XJYujn r74A== Received: by 10.204.9.195 with SMTP id m3mr3587608bkm.78.1334575686885; Mon, 16 Apr 2012 04:28:06 -0700 (PDT) Received: from [95.244.94.95] (host95-94-dynamic.244-95-r.retail.telecomitalia.it. [95.244.94.95]) by mx.google.com with ESMTPS id f5sm30870095bke.9.2012.04.16.04.28.04 (version=SSLv3 cipher=OTHER); Mon, 16 Apr 2012 04:28:05 -0700 (PDT) Message-ID: <4F8C023C.1090306@gmail.com> Date: Mon, 16 Apr 2012 13:27:56 +0200 From: Stefano Lattarini MIME-Version: 1.0 To: Peter Johansson Subject: Re: recheck not dependent on all: References: <4F8BC3E9.70503@gmail.com> In-Reply-To: <4F8BC3E9.70503@gmail.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 208.118.235.17 X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: submit Cc: automake@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) [CC:ing bug-automake so that we won't forget about the issue] On 04/16/2012 09:02 AM, Peter Johansson wrote: > Hello, > > I find the recheck target very handy. In most projects we have a recursive > structure and added a > > recheck: all > (cd test && make $@) > > in top_dir. And typically I work like > > edit sources > make recheck VERBOSE=1 -j8 > edit source > etc > > which works very nice. Now I've started to work in a project with non-recursive > Makefile and I tried working the same fashion but got very confused until I > realized recheck does not depend on all, so my changes in source did not affect > the test result unless i did > > make all -j8 && make recheck VERBOSE=1 -j8 > > I'm just curious; why isn't 'recheck' automatically doing that for me in the > same fashion as 'check' depends on 'all'. > No good reason that I can think of actually; maybe it is just a wart that has been there since day one. I'll take a look shortly; probably this is something we can solve before Automake 1.12 (in which case we'd better release another beta as well). Thanks, Stefano From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 16 12:24:06 2012 Received: (at control) by debbugs.gnu.org; 16 Apr 2012 16:24:06 +0000 Received: from localhost ([127.0.0.1]:37085 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SJoik-0002ZJ-HV for submit@debbugs.gnu.org; Mon, 16 Apr 2012 12:24:06 -0400 Received: from fencepost.gnu.org ([208.118.235.10]:52269 ident=Debian-exim) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SJoij-0002ZC-4k for control@debbugs.gnu.org; Mon, 16 Apr 2012 12:24:05 -0400 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1SJoif-00008X-PL for control@debbugs.gnu.org; Mon, 16 Apr 2012 12:24:01 -0400 Date: Mon, 16 Apr 2012 12:24:01 -0400 Message-Id: Subject: control message for bug 11252 To: X-Mailer: mail (GNU Mailutils 2.1) From: Glenn Morris X-Spam-Score: -6.9 (------) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.9 (------) reassign 11252 automake From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 18 04:35:45 2012 Received: (at control) by debbugs.gnu.org; 18 Apr 2012 08:35:45 +0000 Received: from localhost ([127.0.0.1]:39276 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKQMa-0001fm-IM for submit@debbugs.gnu.org; Wed, 18 Apr 2012 04:35:45 -0400 Received: from mail-bk0-f44.google.com ([209.85.214.44]:44402) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKQMY-0001fZ-Ef for control@debbugs.gnu.org; Wed, 18 Apr 2012 04:35:43 -0400 Received: by bkuw5 with SMTP id w5so5130115bku.3 for ; Wed, 18 Apr 2012 01:35:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:mime-version:to:subject:content-type :content-transfer-encoding; bh=NnK4yw1TGwOumwII7tnsRI4YFVjjyK9/4t17Fszvz0k=; b=EfRJxavgOHWCaxDMAp2ADYRXGgigMkL/p5CatVJPUa0qPyhYz4rfky2YKYHLZ56vcx Ay0PQnRD4mfoJzVDDhlq+2ts54TdH27bHxbubD9Jb8i9MpFFVZkChO0dzPV4AVw2bCMC R7EvRRc4W/8t+vKhxmsxcy91VGSMvqsyjGAoMhpTrcgT6Pi4EtIu+Z6FVmCiAXytJo0i /7qxhRVlbw0/aGPORGAd8x2i3JuQDWEIYSGL5/tuzsuzYbhqYvEcps+nZgE+vQV3oyqv klNpc36owHb9PVbYi6MsRyff96Ajz3DNRNnEgOkLhItQQg8+c82ZBjlJMLJLub6mADjX jwNw== Received: by 10.205.131.3 with SMTP id ho3mr409336bkc.48.1334738124246; Wed, 18 Apr 2012 01:35:24 -0700 (PDT) Received: from [82.58.48.53] (host53-48-dynamic.58-82-r.retail.telecomitalia.it. [82.58.48.53]) by mx.google.com with ESMTPS id f5sm42548869bke.9.2012.04.18.01.35.22 (version=SSLv3 cipher=OTHER); Wed, 18 Apr 2012 01:35:23 -0700 (PDT) Message-ID: <4F8E7CC8.4050004@gmail.com> Date: Wed, 18 Apr 2012 10:35:20 +0200 From: Stefano Lattarini MIME-Version: 1.0 To: control@debbugs.gnu.org Subject: 11252 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) submitter 11252 Peter Johansson thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 18 07:27:49 2012 Received: (at 11252) by debbugs.gnu.org; 18 Apr 2012 11:27:49 +0000 Received: from localhost ([127.0.0.1]:39598 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKT31-0007Qo-CJ for submit@debbugs.gnu.org; Wed, 18 Apr 2012 07:27:49 -0400 Received: from mail-bk0-f44.google.com ([209.85.214.44]:59880) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKT2r-0007QI-Ft for 11252@debbugs.gnu.org; Wed, 18 Apr 2012 07:27:41 -0400 Received: by bkuw5 with SMTP id w5so5264785bku.3 for <11252@debbugs.gnu.org>; Wed, 18 Apr 2012 04:27:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:mime-version:to:subject:content-type; bh=iX8ZQwvFhipBoyeBdJ+W2KFeirVIhSGhlM+Mc/qM7lY=; b=nVHQYfqT18+CaClUYellzBY2GSjIlv1uX9SPxqKvI/orTLkcFmWLncj7xAIyGEcvNq c/uJSaRfm7sib7bA+7gkx+5M3oabtFjpMRLbYF8knD4rJ47F2ai4LdIncNFVMqWPaPCN QsRwNeDZ9HjgjbUTeYi/eLbkpjPutY+gpJafF2t7xAuFCwFAiAPnckswjQ17AAbECeeg yJYVQsUOT0bEwqfuhHKCKtuVGW780qRbWD5NmuNPZkLhd4Ia4zqjV1Q4yl994vpij0/k trXEHSUwsknqsq0XoqyRPXxrnomHOCbma/4PL1JDt+7hOtKGAvAIeL0AK1u9/c2Za2Yl 3g2g== Received: by 10.204.145.70 with SMTP id c6mr587399bkv.41.1334748434848; Wed, 18 Apr 2012 04:27:14 -0700 (PDT) Received: from [79.10.95.32] (host32-95-dynamic.10-79-r.retail.telecomitalia.it. [79.10.95.32]) by mx.google.com with ESMTPS id iv11sm43605348bkc.16.2012.04.18.04.27.12 (version=SSLv3 cipher=OTHER); Wed, 18 Apr 2012 04:27:13 -0700 (PDT) Message-ID: <4F8EA50E.6000702@gmail.com> Date: Wed, 18 Apr 2012 13:27:10 +0200 From: Stefano Lattarini MIME-Version: 1.0 To: 11252@debbugs.gnu.org, "automake-patches@gnu.org" Subject: Re: recheck not dependent on all: Content-Type: multipart/mixed; boundary="------------010806080608030307050104" X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 11252 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) This is a multi-part message in MIME format. --------------010806080608030307050104 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit tags 11252 + patch close 11252 thanks I've applied the attached patch, which should solve the problem. This fix will appear in the next major automake version (1.12). Regards, Stefano --------------010806080608030307050104 Content-Type: text/x-diff; name="0001-ng-silent-rules-support-for-them-is-always-active-no.patch" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename*0="0001-ng-silent-rules-support-for-them-is-always-active-no.pa"; filename*1="tch" >From efcba6dd230f20726afcb9722df23f9b95b43eda Mon Sep 17 00:00:00 2001 Message-Id: From: Stefano Lattarini Date: Tue, 17 Apr 2012 11:48:01 +0200 Subject: [PATCH] [ng] silent rules: support for them is always active now At the time of writing, in mainstream Automake, support for silent rules is optional and activated only if the 'silent-rules' option is specified. The rationale behind this behaviour is that the silent-rules machinery originally [1] only worked with make implementations supporting nested variables expansions, which wasn't a POSIX-specified features, so that packages wanting to be "extra-portable" couldn't use the silent-rules machinery at all. But since Automake-NG only targets GNU make, and since silent rules are disabled by default even when the 'silent-rules' option is given [2], we can now have the support for silent rules always enabled. The 'silent-rules' option will thus become a no-op, but will reaming a valid option for the time being, for better backward-compatibility. [NOTES] [1] At least, until Paul Eggert's commit 'v1.11-598-g8493499' of 25-12-2011, "silent-rules: fallback for makes without nested vars", motivate by automake bugs #9928 and #10237. [2] Unless the developer makes them enabled by default be calling "AM_SILENT_RULES([yes])" in configure.ac. [DETAILS] For more details, see this thread on the automake-ng mailing list: * automake.in: Enable silent-rules machinery unconditionally. Reword some comments. * m4/init.m4: Call 'AC_REQUIRE' on 'AM_SILENT_RULES' unconditionally. * lib/Automake/Options.pm: Recognize 'silent-rules' as a dummy option * t/silent.sh: Remove now-redundant calls to AM_SILENT_RULES. * t/silent2.sh: Likewise. * t/silent3.sh: Likewise. * t/silent4.sh: Likewise. * t/silent6.sh: Likewise. * t/silent8.sh: Likewise. * t/silent9.sh: Likewise. * t/silent-lex.sh: Likewise. * t/silent-many-gcc.sh: Likewise. * t/silent-many-generic.sh: Likewise. * t/silent-yacc-headers.sh: Likewise. * t/silent-yacc.sh: Likewise. * t/silentcxx-gcc.sh: Likewise. * t/silentcxx.sh: Likewise. * t/silentf77.sh: Likewise. * t/silentf90.sh: Likewise. * t/help-silent.sh: Likewise. * t/silent-configsite.sh: Likewise, and other minor adjustments. * t/silent7.sh: Likewise. Also, extend to check that silent rules are disabled by default, and remove obsoleted checks about the 'silent-rules' option being rejected in AUTOMAKE_OPTIONS. * t/compile_f_c_cxx.sh: Adjust to avoid a spurious failure. * t/silent-amopts.sh: Remove as obsolete. * t/list-of-tests.mk: Adjust. * NG-NEWS: Update. * doc/automake.texi: Update and simplify accordingly. * configure.ac (AM_INIT_AUTOMAKE): Remove 'silent-rules' option. Signed-off-by: Stefano Lattarini --- NG-NEWS | 5 +++ automake.in | 51 +++++++++++---------------- configure.ac | 2 +- doc/automake.texi | 87 ++++++++++++---------------------------------- lib/Automake/Options.pm | 1 + m4/init.m4 | 2 +- t/compile_f_c_cxx.sh | 6 ++-- t/help-silent.sh | 19 +++++----- t/list-of-tests.mk | 1 - t/silent-amopts.sh | 28 --------------- t/silent-configsite.sh | 12 ++++--- t/silent-lex.sh | 1 - t/silent-many-gcc.sh | 1 - t/silent-many-generic.sh | 1 - t/silent-yacc-headers.sh | 1 - t/silent-yacc.sh | 1 - t/silent.sh | 1 - t/silent2.sh | 1 - t/silent3.sh | 1 - t/silent4.sh | 1 - t/silent6.sh | 1 - t/silent7.sh | 14 +++----- t/silent8.sh | 5 +-- t/silent9.sh | 1 - t/silentcxx-gcc.sh | 1 - t/silentcxx.sh | 1 - t/silentf77.sh | 1 - t/silentf90.sh | 1 - 28 files changed, 76 insertions(+), 172 deletions(-) delete mode 100755 t/silent-amopts.sh diff --git a/NG-NEWS b/NG-NEWS index 6da558e..152fecc 100644 --- a/NG-NEWS +++ b/NG-NEWS @@ -23,6 +23,11 @@ Automatic dependency tracking support Silent rules ============ +* Support for silent rules is now always active in Makefiles generated + by Automake-NG; so, although the verbose output is still the default, + the user can now always use "./configure --enable-silent-rules" or + "make V=0" to enable quieter output in the package he's building. + * The silent-rules support unconditionally assumes that nested variables expansion are supported. Accordingly, the AC_SUBST'd variables '@AM_V@' and'@AM_DEFAULT_V@' have been removed, so that instead of using diff --git a/automake.in b/automake.in index bb47528..552b5af 100644 --- a/automake.in +++ b/automake.in @@ -1101,11 +1101,11 @@ sub backname ($) ################################################################ -# 'silent-rules' mode handling functions. +# Silent rules handling functions. # verbose_var (NAME) # ------------------ -# The public variable stem used to implement 'silent-rules'. +# The public variable stem used to implement silent rules. sub verbose_var ($) { my ($name) = @_; @@ -1114,7 +1114,7 @@ sub verbose_var ($) # verbose_private_var (NAME) # -------------------------- -# The naming policy for the private variables for 'silent-rules'. +# The naming policy for the private variables for silent rules. sub verbose_private_var ($) { my ($name) = @_; @@ -1123,20 +1123,23 @@ sub verbose_private_var ($) # define_verbose_var (NAME, VAL) # ------------------------------ -# For 'silent-rules' mode, setup VAR and dispatcher, to expand to VAL if silent. +# For silent rules, 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); my $silent_var = $pvar . '_0'; - if (option 'silent-rules') + define_variable ($var, + '$(' . $pvar . '_$(V))', + INTERNAL); + define_variable ($pvar . '_', + '$(' . $pvar . '_$(AM_DEFAULT_VERBOSITY))', + INTERNAL); + if (! vardef ($silent_var, TRUE)) { - define_variable ($var, '$(' . $pvar . '_$(V))', INTERNAL); - define_variable ($pvar . '_', '$(' . $pvar . '_$(AM_DEFAULT_VERBOSITY))', INTERNAL); - Automake::Variable::define ($silent_var, VAR_AUTOMAKE, '', TRUE, $val, - '', INTERNAL, VAR_ASIS) - if (! vardef ($silent_var, TRUE)); + Automake::Variable::define ($silent_var, VAR_AUTOMAKE, '', TRUE, + $val, '', INTERNAL, VAR_ASIS); } } @@ -1148,17 +1151,13 @@ sub define_verbose_var ($$) sub verbose_flag ($) { my ($name) = @_; - return '$(' . verbose_var ($name) . ')' - if (option 'silent-rules'); - return ''; + return '$(' . verbose_var ($name) . ')'; } sub verbose_nodep_flag ($) { my ($name) = @_; - return '$(' . verbose_var ($name) . subst ('am__nodep') . ')' - if (option 'silent-rules'); - return ''; + return '$(' . verbose_var ($name) . subst ('am__nodep') . ')'; } # silent_flag @@ -1171,20 +1170,17 @@ sub silent_flag () # define_verbose_tagvar (NAME) # ---------------------------- -# Engage the needed 'silent-rules' machinery for tag NAME. +# Engage the needed silent rules machinery for tag NAME. sub define_verbose_tagvar ($) { my ($name) = @_; - if (option 'silent-rules') - { - define_verbose_var ($name, '@echo " '. $name . ' ' x (8 - length ($name)) . '" $@;'); - define_verbose_var ('at', '@'); - } + define_verbose_var ($name, '@echo " '. $name . ' ' x (8 - length ($name)) . '" $@;'); + define_verbose_var ('at', '@'); } # define_verbose_texinfo # ---------------------- -# Engage the needed 'silent-rules' machinery for assorted texinfo commands. +# Engage the needed silent rules machinery for assorted texinfo commands. sub define_verbose_texinfo () { my @tagvars = ('DVIPS', 'MAKEINFO', 'INFOHTML', 'TEXI2DVI', 'TEXI2PDF'); @@ -1198,7 +1194,7 @@ sub define_verbose_texinfo () # define_verbose_libtool # ---------------------- -# Engage the needed 'silent-rules' machinery for 'libtool --silent'. +# Engage the needed silent rules machinery for 'libtool --silent'. sub define_verbose_libtool () { define_verbose_var ('lt', '--silent'); @@ -1521,7 +1517,7 @@ sub handle_languages define_linker_variable ($languages{'c'}); } - # Always provide the user with 'AM_V_GEN' for 'silent-rules' mode. + # Always provide the user with 'AM_V_GEN' for silent rules. define_verbose_tagvar ('GEN'); } @@ -5118,7 +5114,6 @@ sub scan_autoconf_traces ($) AM_MAINTAINER_MODE => 0, AM_PROG_AR => 0, AM_PROG_CC_C_O => 0, - AM_SILENT_RULES => 0, _AM_SUBST_NOTMAKE => 1, _AM_COND_IF => 1, _AM_COND_ELSE => 1, @@ -5310,10 +5305,6 @@ sub scan_autoconf_traces ($) { $seen_cc_c_o = $where; } - elsif ($macro eq 'AM_SILENT_RULES') - { - set_global_option ('silent-rules', $where); - } elsif ($macro eq '_AM_COND_IF') { cond_stack_if ('', $args[1], $where); diff --git a/configure.ac b/configure.ac index 8d66a75..a00d6ad 100644 --- a/configure.ac +++ b/configure.ac @@ -40,7 +40,7 @@ dnl We call AC_PROG_CC in an unusual way, and only for use in our dnl testsuite, so also use 'no-dependencies' and 'no-define' among dnl the automake options to avoid bloating and potential problems. AM_INIT_AUTOMAKE([dist-xz filename-length-max=99 color-tests - parallel-tests silent-rules no-define no-dependencies]) + parallel-tests no-define no-dependencies]) # The API version is the base version. We must guarantee # compatibility for all releases with the same API version. diff --git a/doc/automake.texi b/doc/automake.texi index b497233..8e5b0d2 100644 --- a/doc/automake.texi +++ b/doc/automake.texi @@ -359,9 +359,9 @@ Conditionals Silencing Make -* Make verbosity:: Make is verbose by default -* Tricks For Silencing Make:: Standard and generic ways to silence make -* Automake silent-rules Option:: How Automake can help in silencing make +* Make verbosity:: Make is verbose by default +* Tricks For Silencing Make:: Standard and generic ways to silence make +* Automake Silent Rules:: How Automake can help in silencing make When Automake Isn't Enough @@ -4069,7 +4069,8 @@ compiler is found. @item AM_SILENT_RULES @acindex AM_SILENT_RULES -Enable the machinery for less verbose build output (@pxref{Options}). +Control the machinery for less verbose build output +(@pxref{Automake Silent Rules}). @item AM_WITH_DMALLOC @acindex AM_WITH_DMALLOC @@ -5481,9 +5482,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-rules} option (@pxref{Options}). - +@command{libtool} can also be influenced by the Automake support +for silent rules (@pxref{Automake Silent Rules}). @node LTLIBOBJS, Libtool Issues, Libtool Flags, A Shared Library @subsection @code{LTLIBOBJS} and @code{LTALLOCA} @@ -10167,23 +10167,6 @@ non-alpha releases. The second form is @samp{@var{major}.@var{minor}@var{alpha}}, where @var{alpha} is a letter; it should be omitted for non-alpha releases. -@item @option{silent-rules} -@cindex Option, @option{silent-rules} -@opindex silent-rules -Enable less verbose build rules. This can be used to let build rules -output status lines of the form: -@example -GEN @var{output-file} - CC @var{object-file} -@end example -@noindent -instead of printing the command that will be executed to update -@var{output-file} or to compile @var{object-file}. It can also -silence @command{libtool} output. - -For more information about how to use, enable, or disable silent -rules, @pxref{Automake silent-rules Option}. - @item @option{std-options} @cindex Options, @option{std-options} @cindex @samp{make installcheck}, testing @option{--help} and @option{--version} @@ -10665,9 +10648,9 @@ Libtool Sources}). @cindex Silent @command{make} rules @menu -* Make verbosity:: Make is verbose by default -* Tricks For Silencing Make:: Standard and generic ways to silence make -* Automake silent-rules Option:: How Automake can help in silencing make +* Make verbosity:: Make is verbose by default +* Tricks For Silencing Make:: Standard and generic ways to silence make +* Automake Silent Rules:: How Automake can help in silencing make @end menu @node Make verbosity @@ -10702,8 +10685,8 @@ the easy detection of potentially important warning messages. Here we describe some common idioms/tricks to obtain a quieter make output, with their relative advantages and drawbacks. In the next -section (@ref{Automake silent-rules Option}) we'll see how Automake -can help in this respect. +section (@ref{Automake Silent Rules}) we'll see how Automake can help +in this respect, providing more elaborate and flexible idioms. @itemize @bullet @@ -10755,20 +10738,19 @@ automatically activated if the @option{-s} flag is used. @end itemize -@node Automake silent-rules Option +@node Automake Silent Rules @section How Automake can help in silencing make The tricks and idioms for silencing @command{make} described in the previous section can be useful from time to time, but we've seen that they all have their serious drawbacks and limitations. That's why automake provides support for a more advanced and flexible way of -obtaining quieter output from @command{make}: the @option{silent-rules} -mode. +obtaining quieter output from @command{make} (for most rules at least). @c TODO: Maybe describe in brief the precedent set by the build system @c of the Linux Kernel, from which Automake took inspiration ... Links? -To give the gist of what @option{silent-rules} can do, here is a simple +To give the gist of what Automake can do in this respect, here is a simple comparison between a typical @command{make} output (where silent rules are disabled) and one with silent rules enabled: @@ -10817,7 +10799,7 @@ func.c:4:3: warning: ā€˜i’ used uninitialized in this function CCLD foo @end example -@cindex silent-rules and libtool +@cindex silent rules and libtool Also, in projects using @command{libtool}, the use of silent rules can automatically enable the @command{libtool}'s @option{--silent} option: @@ -10843,26 +10825,9 @@ libtool: link: cd .libs && rm -f libx.so && ln -s libx.so.0.0.0 libx.so CCLD libx.la @end example -Let's now see how the @option{silent-rules} mode interfaces with the -package developer and the package user. - -To enable the use of @option{silent-rules} in his package, a developer -needs to do either of the following: - -@itemize @bullet -@item -Add the @option{silent-rules} option as argument to @code{AM_INIT_AUTOMAKE}. -@item -Call the @code{AM_SILENT_RULES} macro from within the @file{configure.ac} -file. -@end itemize - -It is not possible to instead specify @option{silent-rules} in a -@file{Makefile.am} file. - -If the developer has done either of the above, then the user of the -package may influence the verbosity at @command{configure} run time as -well as at @command{make} run time: +For Automake-generated @file{Makefile}s, the user may influence the +verbosity at @command{configure} run time as well as at @command{make} +run time: @itemize @bullet @item @@ -10878,17 +10843,16 @@ time may be overridden: @code{make V=1} will produce verbose output, @code{make V=0} less verbose output. @end itemize -@cindex default verbosity for silent-rules +@cindex default verbosity for silent rules Note that silent rules are @emph{disabled} by default; the user must enable them explicitly at either @command{configure} run time or at @command{make} run time. We think that this is a good policy, since it provides the casual user with enough information to prepare a good bug report in case anything breaks. -Still, notwithstanding the rationales above, a developer who wants to -make silent rules enabled by default in his own package can do so by -adding a @samp{yes} argument to the @code{AM_SILENT_RULES} call in -@file{configure.ac}. We advise against this approach, though. +Still, notwithstanding the rationales above, a developer who really +wants to make silent rules enabled by default in his own package can +do so by calling @code{AM_SILENT_RULES([yes])} in @file{configure.ac}. @c Keep in sync with silent-configsite.sh Users who prefer to have silent rules enabled by default can edit their @@ -10896,11 +10860,6 @@ Users who prefer to have silent rules enabled by default can edit their default to @samp{yes}. This should still allow disabling silent rules at @command{configure} time and at @command{make} time. -@c FIXME: there's really a need to specify this explicitly? -For portability to different @command{make} implementations, package authors -are advised to not set the variable @code{V} inside the @file{Makefile.am} -file, to allow the user to override the value for subdirectories as well. - @vindex @code{AM_V_GEN} @vindex @code{AM_V_at} @vindex @code{AM_DEFAULT_VERBOSITY} diff --git a/lib/Automake/Options.pm b/lib/Automake/Options.pm index 2f977bd..702d428 100644 --- a/lib/Automake/Options.pm +++ b/lib/Automake/Options.pm @@ -287,6 +287,7 @@ sub _is_valid_easy_option ($) no-texinfo.tex nostdinc readme-alpha + silent-rules std-options subdir-objects ); diff --git a/m4/init.m4 b/m4/init.m4 index ef0d3da..dfad84a 100644 --- a/m4/init.m4 +++ b/m4/init.m4 @@ -100,7 +100,7 @@ AC_PROVIDE_IFELSE([AC_PROG_OBJC], [define([AC_PROG_OBJC], defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl ]) -_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl +AC_REQUIRE([AM_SILENT_RULES])dnl dnl The 'parallel-tests' driver may need to know about EXEEXT, so add the dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. diff --git a/t/compile_f_c_cxx.sh b/t/compile_f_c_cxx.sh index 99893d8..2f093ba 100755 --- a/t/compile_f_c_cxx.sh +++ b/t/compile_f_c_cxx.sh @@ -39,8 +39,8 @@ $ACLOCAL $AUTOMAKE # Look for the macros at the beginning of rules. -$FGREP "$tab\$(COMPILE)" Makefile.in -$FGREP "$tab\$(CXXCOMPILE)" Makefile.in -$FGREP "$tab\$(F77COMPILE)" Makefile.in +$FGREP "$tab\$(AM_V_CC)\$(COMPILE)" Makefile.in +$FGREP "$tab\$(AM_V_CXX)\$(CXXCOMPILE)" Makefile.in +$FGREP "$tab\$(AM_V_F77)\$(F77COMPILE)" Makefile.in : diff --git a/t/help-silent.sh b/t/help-silent.sh index d5fc342..aaa6b6a 100755 --- a/t/help-silent.sh +++ b/t/help-silent.sh @@ -14,25 +14,22 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -# Make sure that our macro 'AM_SILENT_RULES' adds proper text to -# the configure help screen. +# Make sure configure options relative to automake silent rules are +# added to the configure help screen. . ./defs || Exit 1 -cat > configure.ac < Makefile.am $ACLOCAL -mv -f configure.ac configure.tmpl +cp configure.ac configure.tmpl q="[\`'\"]" -for args in '' '([])' '([yes])' '([no])'; do - sed "s/AM_SILENT_RULES.*/&$args/" configure.tmpl >configure.ac - cat configure.ac +for args in '' 'yes' 'no'; do + cp -f configure.tmpl configure.ac + test x"$args" = x || echo "AM_SILENT_RULES([$args])/" >> configure.ac + cat configure.ac # For debugging. $AUTOCONF --force grep_configure_help --enable-silent-rules \ " less verbose build.*\\(undo.*${q}make V=1${q}" diff --git a/t/list-of-tests.mk b/t/list-of-tests.mk index 30538e1..9a64d0e 100644 --- a/t/list-of-tests.mk +++ b/t/list-of-tests.mk @@ -956,7 +956,6 @@ t/silentcxx.sh \ t/silentcxx-gcc.sh \ t/silentf77.sh \ t/silentf90.sh \ -t/silent-amopts.sh \ t/silent-many-gcc.sh \ t/silent-many-generic.sh \ t/silent-configsite.sh \ diff --git a/t/silent-amopts.sh b/t/silent-amopts.sh deleted file mode 100755 index f71ad13..0000000 --- a/t/silent-amopts.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh -# Copyright (C) 2012 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 -# the Free Software Foundation; either version 2, or (at your option) -# any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see . - -# Check that automake complaints if the 'silent-rules' option is -# used in AUTOMAKE_OPTIONS. - -. ./defs || Exit 1 - -echo AUTOMAKE_OPTIONS = silent-rules > Makefile.am - -$ACLOCAL -AUTOMAKE_fails -grep "^Makefile\.am:1:.*'silent-rules'.*AM_INIT_AUTOMAKE" stderr - -: diff --git a/t/silent-configsite.sh b/t/silent-configsite.sh index 813753b..d8c2b33 100755 --- a/t/silent-configsite.sh +++ b/t/silent-configsite.sh @@ -21,7 +21,7 @@ . ./defs || Exit 1 cat >> configure.ac <<'EOF' -AM_SILENT_RULES +# This line will be edited later to force silent-rules default. AC_OUTPUT EOF @@ -51,8 +51,9 @@ $MAKE distclean : 'Disable by default in configure.ac, enable by default in config.site' -sed 's/^AM_SILENT_RULES/&([no])/' configure.ac > configure.tmp -mv -f configure.tmp configure.ac +sed 's/.*silent-rules default.*/AM_SILENT_RULES([no])/' configure.ac > t +diff t configure.ac && fatal_ "editing configure.ac" +mv -f t configure.ac $ACLOCAL $AUTOCONF $AUTOMAKE --add-missing @@ -67,8 +68,9 @@ $MAKE distclean : 'Enable by default in configure.ac, disable by default in config.site' -sed 's/^AM_SILENT_RULES/&([yes])/' configure.ac > configure.tmp -mv -f configure.tmp configure.ac +sed 's/.*AM_SILENT_RULES.*/AM_SILENT_RULES([yes])/' configure.ac > t +diff t configure.ac && fatal_ "editing configure.ac" +mv -f t configure.ac $ACLOCAL $AUTOCONF $AUTOMAKE --add-missing diff --git a/t/silent-lex.sh b/t/silent-lex.sh index 2838d6e..0e7bca5 100755 --- a/t/silent-lex.sh +++ b/t/silent-lex.sh @@ -22,7 +22,6 @@ required=lex mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AM_PROG_CC_C_O AC_PROG_LEX AC_CONFIG_FILES([sub/Makefile]) diff --git a/t/silent-many-gcc.sh b/t/silent-many-gcc.sh index 8b457ca..8ad0720 100755 --- a/t/silent-many-gcc.sh +++ b/t/silent-many-gcc.sh @@ -95,7 +95,6 @@ do_and_check_verbose_build () mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AM_PROG_CC_C_O AC_PROG_CXX AC_PROG_F77 diff --git a/t/silent-many-generic.sh b/t/silent-many-generic.sh index 3949009..cd37672 100755 --- a/t/silent-many-generic.sh +++ b/t/silent-many-generic.sh @@ -96,7 +96,6 @@ do_and_check_verbose_build () mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AM_PROG_CC_C_O AC_PROG_F77 AC_PROG_FC diff --git a/t/silent-yacc-headers.sh b/t/silent-yacc-headers.sh index 55ba247..5f12c18 100755 --- a/t/silent-yacc-headers.sh +++ b/t/silent-yacc-headers.sh @@ -23,7 +23,6 @@ required=yacc mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_PROG_YACC AC_PROG_CC AC_OUTPUT diff --git a/t/silent-yacc.sh b/t/silent-yacc.sh index 35415bf..5cb3abc 100755 --- a/t/silent-yacc.sh +++ b/t/silent-yacc.sh @@ -23,7 +23,6 @@ required=yacc mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AM_PROG_CC_C_O AC_PROG_YACC AC_CONFIG_FILES([sub/Makefile]) diff --git a/t/silent.sh b/t/silent.sh index f914c44..3cdbaff 100755 --- a/t/silent.sh +++ b/t/silent.sh @@ -24,7 +24,6 @@ required=cc mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_CONFIG_FILES([sub/Makefile]) AC_PROG_CC AM_PROG_CC_C_O diff --git a/t/silent2.sh b/t/silent2.sh index 6565a27..6270104 100755 --- a/t/silent2.sh +++ b/t/silent2.sh @@ -25,7 +25,6 @@ required=gcc mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_CONFIG_FILES([sub/Makefile]) AC_PROG_CC AM_PROG_CC_C_O diff --git a/t/silent3.sh b/t/silent3.sh index 564a490..cb3c629 100755 --- a/t/silent3.sh +++ b/t/silent3.sh @@ -24,7 +24,6 @@ required='cc libtoolize' mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_CONFIG_FILES([sub/Makefile]) AC_PROG_CC AM_PROG_AR diff --git a/t/silent4.sh b/t/silent4.sh index 44b7eb3..a44c718 100755 --- a/t/silent4.sh +++ b/t/silent4.sh @@ -25,7 +25,6 @@ required="libtoolize gcc" mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_CONFIG_FILES([sub/Makefile]) AC_PROG_CC AM_PROG_AR diff --git a/t/silent6.sh b/t/silent6.sh index 8440643..a493e3e 100755 --- a/t/silent6.sh +++ b/t/silent6.sh @@ -19,7 +19,6 @@ . ./defs || Exit 1 cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_OUTPUT EOF diff --git a/t/silent7.sh b/t/silent7.sh index 02ef287..716eada 100755 --- a/t/silent7.sh +++ b/t/silent7.sh @@ -15,13 +15,11 @@ # along with this program. If not, see . # Check user extensibility of silent-rules mode. +# Aslo check that silent rules are disabled by default. . ./defs || Exit 1 -cat >>configure.ac <<'EOF' -AM_SILENT_RULES -AC_OUTPUT -EOF +echo AC_OUTPUT >> configure.ac cat > Makefile.am <<'EOF' all-local: foo @@ -41,7 +39,9 @@ $ACLOCAL $AUTOMAKE --add-missing $AUTOCONF -./configure --disable-silent-rules +# Silent rules are disabled by default, since we haven't called +# "AM_SILENT_RULES([yes])" explicitly. +./configure $MAKE >stdout || { cat stdout; Exit 1; } cat stdout grep 'GEN ' stdout && Exit 1 @@ -85,8 +85,4 @@ grep 'GEN ' stdout && Exit 1 grep 'cp ' stdout grep 'echo ' stdout -# Ensure that setting 'silent-rules' in a Makefile.am produces an error. -echo 'AUTOMAKE_OPTIONS = silent-rules' >> Makefile.am -AUTOMAKE_fails --force - : diff --git a/t/silent8.sh b/t/silent8.sh index b2059a8..1254f9f 100755 --- a/t/silent8.sh +++ b/t/silent8.sh @@ -19,10 +19,7 @@ required='makeinfo-html tex texi2dvi-o dvips' . ./defs || Exit 1 -cat >>configure.ac <<'EOF' -AM_SILENT_RULES -AC_OUTPUT -EOF +echo AC_OUTPUT >> configure.ac cat > Makefile.am <<'EOF' info_TEXINFOS = foo.texi diff --git a/t/silent9.sh b/t/silent9.sh index 70195a1..9b311c6 100755 --- a/t/silent9.sh +++ b/t/silent9.sh @@ -24,7 +24,6 @@ required='cc libtoolize' mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_CONFIG_FILES([sub/Makefile]) AC_PROG_CC AM_PROG_CC_C_O diff --git a/t/silentcxx-gcc.sh b/t/silentcxx-gcc.sh index d99f1e9..fff3f91 100755 --- a/t/silentcxx-gcc.sh +++ b/t/silentcxx-gcc.sh @@ -24,7 +24,6 @@ required=g++ mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_PROG_CXX AC_CONFIG_FILES([sub/Makefile]) AC_OUTPUT diff --git a/t/silentcxx.sh b/t/silentcxx.sh index a41cc2d..cc111d3 100755 --- a/t/silentcxx.sh +++ b/t/silentcxx.sh @@ -25,7 +25,6 @@ required=c++ mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_PROG_CXX AC_CONFIG_FILES([sub/Makefile]) AC_OUTPUT diff --git a/t/silentf77.sh b/t/silentf77.sh index ce6f6a0..87fbc23 100755 --- a/t/silentf77.sh +++ b/t/silentf77.sh @@ -23,7 +23,6 @@ required=fortran77 mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_PROG_F77 AC_CONFIG_FILES([sub/Makefile]) AC_OUTPUT diff --git a/t/silentf90.sh b/t/silentf90.sh index 8bb06b2..65a35ed 100755 --- a/t/silentf90.sh +++ b/t/silentf90.sh @@ -23,7 +23,6 @@ required=fortran mkdir sub cat >>configure.ac <<'EOF' -AM_SILENT_RULES AC_PROG_FC AC_CONFIG_FILES([sub/Makefile]) AC_OUTPUT -- 1.7.9.5 --------------010806080608030307050104-- From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 18 07:27:50 2012 Received: (at control) by debbugs.gnu.org; 18 Apr 2012 11:27:50 +0000 Received: from localhost ([127.0.0.1]:39601 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKT37-0007R1-Pf for submit@debbugs.gnu.org; Wed, 18 Apr 2012 07:27:50 -0400 Received: from mail-bk0-f44.google.com ([209.85.214.44]:59880) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKT32-0007QI-9Q for control@debbugs.gnu.org; Wed, 18 Apr 2012 07:27:44 -0400 Received: by mail-bk0-f44.google.com with SMTP id w5so5264785bku.3 for ; Wed, 18 Apr 2012 04:27:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:mime-version:to:subject:content-type :content-transfer-encoding; bh=uyiRwOplJ2htpBBg9I6Ms9BdO9ViwmgrwKBMKNRqY7E=; b=u/ZmCS7Mg4AHlnKsPT9HXbXa0AvO8mXlhrSL8KK2C2kwcokzHIxrJtYvtIFNku33XM rWRrmOd0YdOVn/DJl667yA9kTb13te32Jb+na+8lkJyf16gKO1/mfVmuEpIoF1LYSf2w LidXZ9wjQfdU5JOx0+0PFll2bX6kJjUB9/vmoE8EWPi8eLyfUpiLnc+TQnPMNR7qzFfZ dryIbzt6ke+i1hNH2XTIeCoNrEVarwIzLSqCQQ7k91uxoSplu2hvxDAf2lTmDsaSs4oJ YBiKiYwWyAewJWlcygpO4dFsDi2K27/bl1wz0sWsY/FKVnbJsQOXfApYeEfjX01fhbeq 1NuA== Received: by 10.204.129.21 with SMTP id m21mr557234bks.124.1334748450980; Wed, 18 Apr 2012 04:27:30 -0700 (PDT) Received: from [79.10.95.32] (host32-95-dynamic.10-79-r.retail.telecomitalia.it. [79.10.95.32]) by mx.google.com with ESMTPS id u16sm43620642bkf.10.2012.04.18.04.27.27 (version=SSLv3 cipher=OTHER); Wed, 18 Apr 2012 04:27:28 -0700 (PDT) Message-ID: <4F8EA51E.5050708@gmail.com> Date: Wed, 18 Apr 2012 13:27:26 +0200 From: Stefano Lattarini MIME-Version: 1.0 To: control@debbugs.gnu.org Subject: x Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) tags 11252 + patch close 11252 thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 18 09:00:23 2012 Received: (at 11252) by debbugs.gnu.org; 18 Apr 2012 13:00:24 +0000 Received: from localhost ([127.0.0.1]:39673 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKUUb-0002od-SR for submit@debbugs.gnu.org; Wed, 18 Apr 2012 09:00:23 -0400 Received: from mail-bk0-f44.google.com ([209.85.214.44]:63391) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SKUUS-0002nv-Jy for 11252@debbugs.gnu.org; Wed, 18 Apr 2012 09:00:15 -0400 Received: by bkuw5 with SMTP id w5so5339498bku.3 for <11252@debbugs.gnu.org>; Wed, 18 Apr 2012 05:59:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:mime-version:to:subject:references:in-reply-to :content-type; bh=70fL+rRlG/MBhIRG2opPMouV/GaWv50AEuXrFqP89JI=; b=LC88fRkpv16Z8fSB6wv1fhXWsY9/0jVTFnYmxu4oyGGaSqnOOIK72bDUaVZ3ByyDYS 0rhJySYqXuNSnYhTSF0QDlxJODMjGEpErrXRYijuquTNwHkcpc/HPJpkvx2nwfhKrLtk 7MjNru+67fGm/NsSE7FgX6Ya2xBfESqWf+ZxSmf7U0idU0b20vA3dUoN06uz2Q4xmmqZ vvwmOBo2Fp6DVK0GXXtX+OMbpq+iGGPGAtxa9XmOCtGC+eZVbFDxgLLQywSFUxx03MCM toa1EJguY6kEAajqk98haSF2YS6lnsFx4rIfdtP1zSo4oLNvDNYQWPHvePTTnTDL6yOk ASCg== Received: by 10.204.156.12 with SMTP id u12mr701870bkw.33.1334753989312; Wed, 18 Apr 2012 05:59:49 -0700 (PDT) Received: from [79.10.95.32] (host32-95-dynamic.10-79-r.retail.telecomitalia.it. [79.10.95.32]) by mx.google.com with ESMTPS id cy11sm44185194bkb.7.2012.04.18.05.59.45 (version=SSLv3 cipher=OTHER); Wed, 18 Apr 2012 05:59:48 -0700 (PDT) Message-ID: <4F8EBAB8.9010606@gmail.com> Date: Wed, 18 Apr 2012 14:59:36 +0200 From: Stefano Lattarini MIME-Version: 1.0 To: 11252@debbugs.gnu.org, "automake-patches@gnu.org" Subject: Re: bug#11252: recheck not dependent on all: References: <4F8C023C.1090306@gmail.com> <4F8EA50E.6000702@gmail.com> In-Reply-To: <4F8EA50E.6000702@gmail.com> Content-Type: multipart/mixed; boundary="------------050903080005020108000109" X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 11252 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) This is a multi-part message in MIME format. --------------050903080005020108000109 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit On 04/18/2012 01:27 PM, Stefano Lattarini wrote: > tags 11252 + patch > close 11252 > thanks > > I've applied the attached patch, which should solve the problem. This > fix will appear in the next major automake version (1.12). > Oops, I had attached the wrong patch (thanks to Peter Rosin for pointing that out privately). Here is the correct patch. Sorry for the noise, Stefano --------------050903080005020108000109 Content-Type: text/x-diff; name="0001-parallel-tests-recheck-must-depend-on-all.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0001-parallel-tests-recheck-must-depend-on-all.patch" >From f46359b42790945e42e78a620e651ce66c2b8833 Mon Sep 17 00:00:00 2001 Message-Id: From: Stefano Lattarini Date: Wed, 18 Apr 2012 11:40:15 +0200 Subject: [PATCH] parallel-tests: 'recheck' must depend on 'all' Fixes automake bug#11252. When a developer experience one or more failures in the testsuite, a good workflow is for him to modify its program's sources to fix the bug thus revealed, run "make recheck" to verify that the change has indeed solved the testsuite failures previously experienced, and then run "make check" to verify that the change has not introduced any new failure or regression. Unfortunately, this apparently natural workflow couldn't have worked until now, since the Automake-provided 'recheck' target (which didn't depend on 'all') wouldn't have causes the program to be recompiled, and the failed tests would have thus been run with the older, buggy version of the program, failing the same way as before. * lib/am/check.am (recheck): Depend on 'all'. * t/parallel-tests-recheck-depends-on-all.sh: New test. * t/list-of-tests.mk: Add it. * NEWS: Update. Signed-off-by: Stefano Lattarini --- NEWS | 4 ++ lib/am/check.am | 3 +- t/list-of-tests.mk | 1 + t/parallel-tests-recheck-depends-on-all.sh | 93 ++++++++++++++++++++++++++++ 4 files changed, 100 insertions(+), 1 deletion(-) create mode 100755 t/parallel-tests-recheck-depends-on-all.sh diff --git a/NEWS b/NEWS index 142f805..bb2480f 100644 --- a/NEWS +++ b/NEWS @@ -92,6 +92,10 @@ New in 1.11c: testsuite harness. This is still the default at the moment, but it might change in future versions. + - The 'recheck' target (provided by the parallel testsuite harness) now + depends on the 'all' target. This allows for a better user-experience + in test-driven development. See automake bug#11252. + - Test scripts that exit with status 99 to signal an "hard error" (e.g., and unexpected or internal error, or a failure to set up the test case scenario) have their outcome reported as an 'ERROR' now. Previous diff --git a/lib/am/check.am b/lib/am/check.am index 0ce064d..7866570 100644 --- a/lib/am/check.am +++ b/lib/am/check.am @@ -367,7 +367,8 @@ check-TESTS recheck: $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list" ## Recheck must depend on $(check_SCRIPTS), $(check_PROGRAMS), etc. -recheck: %CHECK_DEPS% +## It must also depend on the 'all' target. See automake bug#11252. +recheck: all %CHECK_DEPS% AM_RECURSIVE_TARGETS += check recheck diff --git a/t/list-of-tests.mk b/t/list-of-tests.mk index ea77bc1..4562828 100644 --- a/t/list-of-tests.mk +++ b/t/list-of-tests.mk @@ -737,6 +737,7 @@ t/parallel-tests6.sh \ t/parallel-tests8.sh \ t/parallel-tests9.sh \ t/parallel-tests10.sh \ +t/parallel-tests-recheck-depends-on-all.sh \ t/parallel-tests-exeext.sh \ t/parallel-tests-suffix.sh \ t/parallel-tests-suffix-prog.sh \ diff --git a/t/parallel-tests-recheck-depends-on-all.sh b/t/parallel-tests-recheck-depends-on-all.sh new file mode 100755 index 0000000..cec66ae --- /dev/null +++ b/t/parallel-tests-recheck-depends-on-all.sh @@ -0,0 +1,93 @@ +#! /bin/sh +# Copyright (C) 2012 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 +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +# The parallel-tests 'recheck' target must depend on the 'all' target. +# See automake bug#11252. + +am_parallel_tests=yes +required=cc +. ./defs || Exit 1 + +cat >> configure.ac << 'END' +AC_PROG_CC +AC_OUTPUT +END + +cat > Makefile.am << 'END' +all-local: + test ! -f status || echo okokok > status +bin_PROGRAMS = foo +TESTS = a.test b.test c.test +END + +cat > foo.c << 'END' +#include +int main (void) +{ + printf ("failure :-(" "\n"); + return 1; +} +END + +cat > a.test << 'END' +#!/bin/sh +exit 0 +END + +cat > b.test << 'END' +#!/bin/sh +grep okokok status +END + +cat > c.test << 'END' +#!/bin/sh +./foo +END + +chmod a+x *.test + +$ACLOCAL +$AUTOCONF +$AUTOMAKE -a +./configure + +$MAKE check >stdout && { cat stdout; Exit 1; } +cat stdout +count_test_results total=3 pass=1 fail=2 skip=0 xfail=0 xpass=0 error=0 +test ! -f status + +$sleep +: > status +cat > foo.c << 'END' +#include +int main (void) +{ + printf ("success :-)" "\n"); + return 0; +} +END + +$MAKE recheck >stdout || { cat stdout; Exit 1; } +cat stdout +count_test_results total=2 pass=2 fail=0 skip=0 xfail=0 xpass=0 error=0 +grep '^PASS: b\.test$' stdout +grep '^PASS: c\.test$' stdout + +$MAKE recheck >stdout || { cat stdout; Exit 1; } +cat stdout +count_test_results total=0 pass=0 fail=0 skip=0 xfail=0 xpass=0 error=0 + +: -- 1.7.9.5 --------------050903080005020108000109-- From unknown Tue Jun 17 01:46:24 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 17 May 2012 11:24:02 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator