From unknown Sat Sep 06 00:11:38 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#7800 <7800@debbugs.gnu.org> To: bug#7800 <7800@debbugs.gnu.org> Subject: Status: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved Reply-To: bug#7800 <7800@debbugs.gnu.org> Date: Sat, 06 Sep 2025 07:11:38 +0000 retitle 7800 automake fails to honor `-d' in AM_YFLAGS when variable expans= ions are involved reassign 7800 automake submitter 7800 Stefano Lattarini severity 7800 wishlist tag 7800 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 09:30:06 2011 Received: (at submit) by debbugs.gnu.org; 7 Jan 2011 14:30:06 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbDKQ-0002gH-13 for submit@debbugs.gnu.org; Fri, 07 Jan 2011 09:30:06 -0500 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbDKN-0002fF-Jp for submit@debbugs.gnu.org; Fri, 07 Jan 2011 09:30:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PbDRP-0005PZ-R3 for submit@debbugs.gnu.org; Fri, 07 Jan 2011 09:37:20 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, RFC_ABUSE_POST, T_DKIM_INVALID, T_TO_NO_BRKTS_FREEMAIL autolearn=unavailable version=3.3.1 Received: from lists.gnu.org ([199.232.76.165]:39495) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PbDRP-0005PQ-OR for submit@debbugs.gnu.org; Fri, 07 Jan 2011 09:37:19 -0500 Received: from [140.186.70.92] (port=38995 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PbDRO-0001WB-Md for bug-automake@gnu.org; Fri, 07 Jan 2011 09:37:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PbDRN-0005Ob-3R for bug-automake@gnu.org; Fri, 07 Jan 2011 09:37:18 -0500 Received: from mail-fx0-f41.google.com ([209.85.161.41]:39907) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PbDRM-0005OJ-V9 for bug-automake@gnu.org; Fri, 07 Jan 2011 09:37:17 -0500 Received: by fxm12 with SMTP id 12so10452017fxm.0 for ; Fri, 07 Jan 2011 06:37:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:mime-version:content-type:content-transfer-encoding :message-id; bh=3CG4mwOFOOEvSkL88O0P61SpDynBOzwN1sRdckDONHQ=; b=eKK9XUAjI8L9PmqjzcinP3aiFWgoAwVQZa2xW8BWNRynYHCmQ2D6qnxZ9UQ6xGjjT+ KyyrNLEVk6FU2UAfedI0uJVvpwhQ/I09th9+ZKhU6jPuuI/l31n1unCEwQv1aqg8PBC+ b3MaWP5AE2mmqiXA3sKKYG5YYd7bV0EZWbPvk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:mime-version:content-type :content-transfer-encoding:message-id; b=VgDY1vF6X8VxM/As7b2STGz092Upp6IxmiW612SYJoP2SPnbt8vUtRtrS3ogHmsx/X 23Ha2JAgJ/yM3acYZjk8F23KjwvGHAV/ujgBnU8JE8wj1F92opeQRLpklwZJv3raw6gs Woltdny6zisKtzO6AcNxWlLC6aU3O/mq7XPY0= Received: by 10.223.96.6 with SMTP id f6mr1146485fan.132.1294411035726; Fri, 07 Jan 2011 06:37:15 -0800 (PST) Received: from bigio.localnet (host6-38-dynamic.52-82-r.retail.telecomitalia.it [82.52.38.6]) by mx.google.com with ESMTPS id 5sm6181442fak.47.2011.01.07.06.37.14 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 07 Jan 2011 06:37:14 -0800 (PST) From: Stefano Lattarini To: bug-automake@gnu.org Subject: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved Date: Fri, 7 Jan 2011 15:36:43 +0100 User-Agent: KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <201101071536.44228.stefano.lattarini@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Spam-Score: -4.9 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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: -5.0 (-----) severity: wishlist thanks -*-*- Hello automakers. Currently, automake is not smart enough to resolve variable expansions in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. For example: $ cat configure.ac AC_INIT(x,0) AM_INIT_AUTOMAKE(foreign) AC_PROG_CC AC_PROG_YACC AC_CONFIG_FILES(Makefile) $ cat Makefile.am bin_PROGRAMS = foo bar foo_SOURCES = foo.y bar_SOURCES = bar.y my_YFLAGS = -d AM_YFLAGS = $(my_YFLAGS) bar_YFLAGS = $(my_YFLAGS) $ aclocal $ automake -a $ egrep '(foo|bar).h\.*:' Makefile.in # no match :-( $ sed -i 's/$(my_YFLAGS)/-d/' Makefile.am $ automake $ egrep '(foo|bar)\.h.*:' Makefile.in # now as expected bar-bar.h: bar-bar.c foo.h: foo.c Not sure if this bug is worth fixing, but having it reported in the bug database won't hurt, either (and I might anyway attempt a fix soonish). Regards, Stefano From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 11:54:57 2011 Received: (at 7800) by debbugs.gnu.org; 7 Jan 2011 16:54:57 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbFaa-0006ZH-Gi for submit@debbugs.gnu.org; Fri, 07 Jan 2011 11:54:57 -0500 Received: from mout5.freenet.de ([195.4.92.95]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbFRb-0006N5-BA for 7800@debbugs.gnu.org; Fri, 07 Jan 2011 11:45:40 -0500 Received: from [195.4.92.15] (helo=5.mx.freenet.de) by mout5.freenet.de with esmtpa (ID ralf.corsepius@freenet.de) (port 25) (Exim 4.72 #3) id 1PbFYd-0003G4-LT; Fri, 07 Jan 2011 17:52:55 +0100 Received: from hsi-kbw-078-043-059-079.hsi4.kabel-badenwuerttemberg.de ([78.43.59.79]:64559 helo=[192.168.1.104]) by 5.mx.freenet.de with esmtpsa (ID ralf.corsepius@freenet.de) (TLSv1:CAMELLIA256-SHA:256) (port 587) (Exim 4.72 #3) id 1PbFYd-0005Em-AK; Fri, 07 Jan 2011 17:52:55 +0100 Message-ID: <4D2744E6.3000005@rtems.org> Date: Fri, 07 Jan 2011 17:52:54 +0100 From: Ralf Corsepius User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Thunderbird/3.1.7 MIME-Version: 1.0 To: Stefano Lattarini Subject: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved References: <201101071536.44228.stefano.lattarini@gmail.com> In-Reply-To: <201101071536.44228.stefano.lattarini@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 7800 X-Mailman-Approved-At: Fri, 07 Jan 2011 11:54:55 -0500 Cc: 7800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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 (--) On 01/07/2011 03:36 PM, Stefano Lattarini wrote: > severity: wishlist > thanks > > -*-*- > > Hello automakers. > > Currently, automake is not smart enough to resolve variable expansions > in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. > > For example: > > $ cat configure.ac > AC_INIT(x,0) > AM_INIT_AUTOMAKE(foreign) > AC_PROG_CC > AC_PROG_YACC > AC_CONFIG_FILES(Makefile) > $ cat Makefile.am > bin_PROGRAMS = foo bar > foo_SOURCES = foo.y > bar_SOURCES = bar.y > my_YFLAGS = -d > AM_YFLAGS = $(my_YFLAGS) > bar_YFLAGS = $(my_YFLAGS) > $ aclocal > $ automake -a > $ egrep '(foo|bar).h\.*:' Makefile.in # no match :-( > $ sed -i 's/$(my_YFLAGS)/-d/' Makefile.am > $ automake > $ egrep '(foo|bar)\.h.*:' Makefile.in # now as expected > bar-bar.h: bar-bar.c > foo.h: foo.c > > Not sure if this bug is worth fixing, This once used to work => regression. From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 13:14:05 2011 Received: (at 7800) by debbugs.gnu.org; 7 Jan 2011 18:14:05 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbGpB-0008G6-F3 for submit@debbugs.gnu.org; Fri, 07 Jan 2011 13:14:05 -0500 Received: from mailout-de.gmx.net ([213.165.64.22] helo=mail.gmx.net) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1PbGp9-0008FW-9j for 7800@debbugs.gnu.org; Fri, 07 Jan 2011 13:14:04 -0500 Received: (qmail invoked by alias); 07 Jan 2011 18:21:19 -0000 Received: from xdsl-78-35-60-197.netcologne.de (EHLO localhost.localdomain) [78.35.60.197] by mail.gmx.net (mp054) with SMTP; 07 Jan 2011 19:21:19 +0100 X-Authenticated: #13673931 X-Provags-ID: V01U2FsdGVkX19KHJZwSklKXHAs6VwBKpJpvEfqiKYdcbFz5/Omax roglzZFKnt3TDR Received: from ralf by localhost.localdomain with local (Exim 4.69) (envelope-from ) id 1PbGwB-0003PV-3X; Fri, 07 Jan 2011 19:21:19 +0100 Date: Fri, 7 Jan 2011 19:21:19 +0100 From: Ralf Wildenhues To: Stefano Lattarini Subject: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved Message-ID: <20110107182118.GC12928@gmx.de> References: <201101071536.44228.stefano.lattarini@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201101071536.44228.stefano.lattarini@gmail.com> Organization: Institute for Numerical Simulation, University of Bonn User-Agent: Mutt/1.5.20 (2010-08-04) X-Y-GMX-Trusted: 0 X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 7800 Cc: 7800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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 (--) Hi Stefano, thanks for the report. * Stefano Lattarini wrote on Fri, Jan 07, 2011 at 03:36:43PM CET: > Currently, automake is not smart enough to resolve variable expansions > in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. value_as_list_recursive can usually help here. > Not sure if this bug is worth fixing, but having it reported in the bug > database won't hurt, either (and I might anyway attempt a fix soonish). The usual complication is what to do if - the variable is overridden at 'make' time (automake usually punts in that case), - the variable is conditionally set (this usually requires making the automake code more complex to solve). Punting also for the latter is fine if the feature is expected to be little-used. Cheers, Ralf From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 13:46:07 2011 Received: (at 7800) by debbugs.gnu.org; 7 Jan 2011 18:46:07 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbHKB-0000VH-6p for submit@debbugs.gnu.org; Fri, 07 Jan 2011 13:46:07 -0500 Received: from mailout-de.gmx.net ([213.165.64.23] helo=mail.gmx.net) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1PbHK8-0000Um-8a for 7800@debbugs.gnu.org; Fri, 07 Jan 2011 13:46:05 -0500 Received: (qmail invoked by alias); 07 Jan 2011 18:53:20 -0000 Received: from xdsl-78-35-60-197.netcologne.de (EHLO localhost.localdomain) [78.35.60.197] by mail.gmx.net (mp007) with SMTP; 07 Jan 2011 19:53:20 +0100 X-Authenticated: #13673931 X-Provags-ID: V01U2FsdGVkX1/Pw84Bf1PPi2uAO3lvNVbdPAqf0BO7dndf2tb0d8 KWGUqmao4ZRhxM Received: from ralf by localhost.localdomain with local (Exim 4.69) (envelope-from ) id 1PbHR9-0003SX-Eu; Fri, 07 Jan 2011 19:53:19 +0100 Date: Fri, 7 Jan 2011 19:53:19 +0100 From: Ralf Wildenhues To: Ralf Corsepius Subject: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved Message-ID: <20110107185319.GH12928@gmx.de> References: <201101071536.44228.stefano.lattarini@gmail.com> <4D2744E6.3000005@rtems.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D2744E6.3000005@rtems.org> Organization: Institute for Numerical Simulation, University of Bonn User-Agent: Mutt/1.5.20 (2010-08-04) X-Y-GMX-Trusted: 0 X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 7800 Cc: 7800@debbugs.gnu.org, Stefano Lattarini X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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 (--) Hello Ralf, * Ralf Corsepius wrote on Fri, Jan 07, 2011 at 05:52:54PM CET: > On 01/07/2011 03:36 PM, Stefano Lattarini wrote: > >Currently, automake is not smart enough to resolve variable expansions > >in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. > This once used to work > > => regression. Please, if you make such a statement, include more details: whether you know of an Automake version where this used to work, or have code examples where it did (including a pointer to the code), or have just tried the sample code from the PR. If you don't have more details, then please also state so; even stating some guess is better than not providing any data at all. With just the above, it is hard to judge. Thank you, Ralf From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 14:32:47 2011 Received: (at 7800) by debbugs.gnu.org; 7 Jan 2011 19:32:47 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbI3L-0002I5-G8 for submit@debbugs.gnu.org; Fri, 07 Jan 2011 14:32:47 -0500 Received: from mail-fx0-f44.google.com ([209.85.161.44]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbI3J-0002Ht-QA for 7800@debbugs.gnu.org; Fri, 07 Jan 2011 14:32:46 -0500 Received: by fxm9 with SMTP id 9so16721296fxm.3 for <7800@debbugs.gnu.org>; Fri, 07 Jan 2011 11:40:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id; bh=x4UNSe9Azjv7yXytTzsrtUHqWtKOi6oUwUxeeayuxco=; b=faPPLXTU7wLZpnFcGecwv1xmYNTk8AhGa1Rgsh2c3jjaxWhbl61UoRFkq3i7oS1l9k J+G7OKgVwK7+TZNaUv32aOi3dLNv4M6lZkdlbK2RcA1dZcFOOR0BWhTw/WTExZ2jMeh+ F6pdll4GXC0GAq+ViR2Cw9FtUPOfA5cVPcicU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; b=NCbMZAsudc5ntyVnMK+M0nzA2cExcM3pZ1B1SksVBrAWwBxpG6PqOBR1PWM9Kqq3Uz fJTePsXtkrlqZ8BdTK0wBMWVWr+o36yKAISEVM/RpyJPtYbpNM5igNTH0pY02TlEOha5 X1m28qkyFjt/izJtHk1vPZDoZMhnAFn484mAU= Received: by 10.223.86.3 with SMTP id q3mr1704312fal.139.1294429202864; Fri, 07 Jan 2011 11:40:02 -0800 (PST) Received: from bigio.localnet (host177-52-dynamic.48-82-r.retail.telecomitalia.it [82.48.52.177]) by mx.google.com with ESMTPS id n3sm6265563fax.7.2011.01.07.11.40.01 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 07 Jan 2011 11:40:01 -0800 (PST) From: Stefano Lattarini To: Ralf Wildenhues Subject: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved Date: Fri, 7 Jan 2011 20:39:31 +0100 User-Agent: KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) References: <201101071536.44228.stefano.lattarini@gmail.com> <20110107182118.GC12928@gmx.de> In-Reply-To: <20110107182118.GC12928@gmx.de> MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <201101072039.31714.stefano.lattarini@gmail.com> X-Spam-Score: -3.6 (---) X-Debbugs-Envelope-To: 7800 Cc: 7800@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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: -3.6 (---) On Friday 07 January 2011, Ralf Wildenhues wrote: > Hi Stefano, > > thanks for the report. > > * Stefano Lattarini wrote on Fri, Jan 07, 2011 at 03:36:43PM CET: > > Currently, automake is not smart enough to resolve variable expansions > > in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. > > value_as_list_recursive can usually help here. > > > Not sure if this bug is worth fixing, but having it reported in the bug > > database won't hurt, either (and I might anyway attempt a fix soonish). > > The usual complication is what to do if > - the variable is overridden at 'make' time (automake usually punts in > that case), > - the variable is conditionally set (this usually requires making the > automake code more complex to solve). > Currently, automake errors out if AM_YFLAGS is conditinally defined -- a behaviour I'd like to preserve. BTW, currently it doesn't warn (unfortunately) about something like: AM_YFLAGS = -v if COND AM_YFLAGS += -d endif COND a behaviour I'd like to fix (but that's for another thread anyway). > Punting also for the latter is fine if the feature is expected to be > little-used. > IMHO that's fine also because the feature didn't work before anyway. Thanks, Stefano From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 17:43:58 2011 Received: (at 7800) by debbugs.gnu.org; 7 Jan 2011 22:43:58 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbL2L-0006Iy-HW for submit@debbugs.gnu.org; Fri, 07 Jan 2011 17:43:58 -0500 Received: from mail-fx0-f44.google.com ([209.85.161.44]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbL2I-0006Ik-8s for 7800@debbugs.gnu.org; Fri, 07 Jan 2011 17:43:56 -0500 Received: by fxm9 with SMTP id 9so16874220fxm.3 for <7800@debbugs.gnu.org>; Fri, 07 Jan 2011 14:51:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:content-type :message-id; bh=KP+zoxTZZPgvedIC0H6+zB3z6Bf+4g4ShjDA3kU4Szg=; b=Rc/so4hYbT1Ru4quHt8dnFDsSRS0KfFDBQyaZxXawugF2/8C2PA1jtfg8Su9K2m8Dv cJ9AJl7hhwIQ5HMFdiKxgRPBl5GZvsOHzMpYGBQDsowF6CNXSDYpeoncr0YuPSk1Jy9d h7voH82NCITIZeC1QkrMjkpg73x2gc6Ryab8k= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:message-id; b=hYxsL25NmCJ6oRR4MHeOHIxrRjhOwgfRQmbiuX2E+Ri5DI4UF9J9ww2aHu+l4ISZw6 MxNiBdhnA2VzEjt6nJy6zdRJ58T9ahOZYEJGpWBdqZN0JJunvC8S0rDOO9eY13PJ2/Qx sqDuodlrYpIQjD3E4AvBDXL9Ou/x3lGURuRSk= Received: by 10.223.96.73 with SMTP id g9mr1962788fan.24.1294440671736; Fri, 07 Jan 2011 14:51:11 -0800 (PST) Received: from bigio.localnet (host177-52-dynamic.48-82-r.retail.telecomitalia.it [82.48.52.177]) by mx.google.com with ESMTPS id n2sm6298186fam.28.2011.01.07.14.51.09 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 07 Jan 2011 14:51:10 -0800 (PST) From: Stefano Lattarini To: Ralf Wildenhues Subject: [PATCHES] yacc: support variable expansions in *YFLAGS definition (was: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved) Date: Fri, 7 Jan 2011 23:50:51 +0100 User-Agent: KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) References: <201101071536.44228.stefano.lattarini@gmail.com> <20110107182118.GC12928@gmx.de> In-Reply-To: <20110107182118.GC12928@gmx.de> MIME-Version: 1.0 Content-Type: Multipart/Mixed; boundary="Boundary-00=_Mj5JNwcNGi/Zkm0" Message-Id: <201101072350.53021.stefano.lattarini@gmail.com> X-Spam-Score: -3.6 (---) X-Debbugs-Envelope-To: 7800 Cc: 7800@debbugs.gnu.org, automake-patches@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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: -3.6 (---) --Boundary-00=_Mj5JNwcNGi/Zkm0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Reference: On Friday 07 January 2011, Ralf Wildenhues wrote: > Hi Stefano, > > thanks for the report. > > * Stefano Lattarini wrote on Fri, Jan 07, 2011 at 03:36:43PM CET: > > Currently, automake is not smart enough to resolve variable expansions > > in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. > > value_as_list_recursive can usually help here. > > > Not sure if this bug is worth fixing, but having it reported in the bug > > database won't hurt, either (and I might anyway attempt a fix soonish). > > The usual complication is what to do if > - the variable is overridden at 'make' time (automake usually punts in > that case), > - the variable is conditionally set (this usually requires making the > automake code more complex to solve). > > Punting also for the latter is fine if the feature is expected to be > little-used. > > Cheers, > Ralf > The attached two-patch series should fix the bug (the first patch is a testsuite enhancement, the second one really fixes the bug). OK to apply to the temporary branch 'yacc-clean' (recently merged into master with commit v1.11-575-ga297a16) and merge to master again? Regards, Stefano --Boundary-00=_Mj5JNwcNGi/Zkm0 Content-Type: text/x-patch; charset="us-ascii"; name="0001-tests-more-on-YFLAGS-support.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline; filename="0001-tests-more-on-YFLAGS-support.patch" =46rom 6dc4c48587164bbf6784acddbfe5065b283fe190 Mon Sep 17 00:00:00 2001 =46rom: Stefano Lattarini Date: Fri, 7 Jan 2011 20:52:17 +0100 Subject: [PATCH 1/2] tests: more on *YFLAGS support * tests/yflags-var-expand.test: New test, still xfailing. It exposes automake bug#7800 -- "automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved". * tests/yflags-d-false-positive.test: New test, checking that automake do not spuriously see `-d' in *YFLAGS when that isn't really there. * tests/yflags-force-override.test: New test, checking that automake can cope with definition of the YFLAGS variable in Makefile.am (even if that is an extremely bad practice, as that variable is user-reserved). * tests/yflags-cmdline-override.test: New test, checking that automake can cope with user-redefinition of YFLAGS at configure time and/or at make time. * tests/yflags-conditional.test: New test, checks that automake warns on conditionally-defined *YFLAGS variables. * tests/Makefile.am (TESTS, XFAIL_TESTS): Update. =2D-- ChangeLog | 20 ++++++++ tests/Makefile.am | 6 ++ tests/Makefile.in | 6 ++ tests/yflags-cmdline-override.test | 88 +++++++++++++++++++++++++++++++= ++++ tests/yflags-conditional.test | 46 ++++++++++++++++++ tests/yflags-d-false-positives.test | 42 +++++++++++++++++ tests/yflags-force-override.test | 64 +++++++++++++++++++++++++ tests/yflags-var-expand.test | 63 +++++++++++++++++++++++++ 8 files changed, 335 insertions(+), 0 deletions(-) create mode 100755 tests/yflags-cmdline-override.test create mode 100755 tests/yflags-conditional.test create mode 100755 tests/yflags-d-false-positives.test create mode 100755 tests/yflags-force-override.test create mode 100755 tests/yflags-var-expand.test diff --git a/ChangeLog b/ChangeLog index 2482bbf..143109b 100644 =2D-- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,25 @@ 2011-01-07 Stefano Lattarini =20 + tests: more on *YFLAGS support + * tests/yflags-var-expand.test: New test, still xfailing. It + exposes automake bug#7800 -- "automake fails to honor `-d' in + AM_YFLAGS when variable expansions are involved". + * tests/yflags-d-false-positive.test: New test, checking that + automake do not spuriously see `-d' in *YFLAGS when that isn't + really there. + * tests/yflags-force-override.test: New test, checking that + automake can cope with definition of the YFLAGS variable in + Makefile.am (even if that is an extremely bad practice, as that + variable is user-reserved). + * tests/yflags-cmdline-override.test: New test, checking that + automake can cope with user-redefinition of YFLAGS at configure + time and/or at make time. + * tests/yflags-conditional.test: New test, checks that automake + warns on conditionally-defined *YFLAGS variables. + * tests/Makefile.am (TESTS, XFAIL_TESTS): Update. + +2011-01-07 Stefano Lattarini + yacc: "make clean" removes .c and .h files from non-distributed .y Previously, while automake did *not* distribute C source and header files derived from non-distributed Yacc sources, it still caused diff --git a/tests/Makefile.am b/tests/Makefile.am index bed5e41..0caa8d2 100644 =2D-- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -21,6 +21,7 @@ all.test \ auxdir2.test \ cond17.test \ gcj6.test \ +yflags-var-expand.test \ txinfo5.test =20 include $(srcdir)/parallel-tests.am @@ -807,6 +808,11 @@ yaccpp.test \ yaccvpath.test \ yflags.test \ yflags2.test \ +yflags-cmdline-override.test \ +yflags-conditional.test \ +yflags-d-false-positives.test \ +yflags-force-override.test \ +yflags-var-expand.test \ $(parallel_tests) =20 EXTRA_DIST =3D ChangeLog-old gen-parallel-tests $(TESTS) diff --git a/tests/Makefile.in b/tests/Makefile.in index 77e9a38..94fd7b2 100644 =2D-- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -277,6 +277,7 @@ all.test \ auxdir2.test \ cond17.test \ gcj6.test \ +yflags-var-expand.test \ txinfo5.test =20 parallel_tests =3D \ @@ -1074,6 +1075,11 @@ yaccpp.test \ yaccvpath.test \ yflags.test \ yflags2.test \ +yflags-cmdline-override.test \ +yflags-conditional.test \ +yflags-d-false-positives.test \ +yflags-force-override.test \ +yflags-var-expand.test \ $(parallel_tests) =20 EXTRA_DIST =3D ChangeLog-old gen-parallel-tests $(TESTS) diff --git a/tests/yflags-cmdline-override.test b/tests/yflags-cmdline-over= ride.test new file mode 100755 index 0000000..baedf68 =2D-- /dev/null +++ b/tests/yflags-cmdline-override.test @@ -0,0 +1,88 @@ +#! /bin/sh +# Copyright (C) 2011 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 can cope with user-redefinition of $(YFLAGS) +# at configure time and/or at make time. + +. ./defs || Exit 1 + +set -e + +unset YFLAGS || : + +cat >> configure.in <<'END' +AC_PROG_CC +AC_PROG_YACC +AC_OUTPUT +END + +cat > Makefile.am <<'END' +bin_PROGRAMS =3D foo +foo_SOURCES =3D foo.y +# A minor automake wart: automake doesn't generate the code to clean +# `*.output' files generated by yacc (it's not even clear if that would +# be useful in general, so it's probably better to be conservative). +CLEANFILES =3D foo.output +# Another automake wart: `-d' flag won't be given at automake time, so +# automake won't be able to generate the code to clean `foo.h' :-( +MAINTAINERCLEANFILES =3D foo.h +END + +cat > foo.y << 'END' +%{ +int yylex () { return 0; } +void yyerror (char *s) { return; } +int main () { return 0; } +%} +%% +foobar : 'f' 'o' 'o' 'b' 'a' 'r' {}; +END + +$ACLOCAL +$AUTOMAKE -a +$AUTOCONF + +./configure YFLAGS=3D'-d -v' +$MAKE +ls -l +test -f foo.c +test -f foo.h +test -f foo.output + +$MAKE maintainer-clean +ls -l + +./configure YFLAGS=3D'-v' +$MAKE +ls -l +test -f foo.c +test ! -r foo.h +test -f foo.output + +$MAKE maintainer-clean +ls -l + +./configure YFLAGS=3D'-v' +YFLAGS=3D-d $MAKE -e +ls -l +test -f foo.c +test -f foo.h +test ! -r foo.output + +$MAKE maintainer-clean +ls -l + +: diff --git a/tests/yflags-conditional.test b/tests/yflags-conditional.test new file mode 100755 index 0000000..8c673b1 =2D-- /dev/null +++ b/tests/yflags-conditional.test @@ -0,0 +1,46 @@ +#! /bin/sh +# Copyright (C) 2011 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 complains about conditionally-defined *_YFLAGS. + +. ./defs || Exit 1 + +set -e + +cat >> configure.in <<'END' +AC_PROG_CC +AC_PROG_YACC +AM_CONDITIONAL([COND], [:]) +END + +cat > Makefile.am <<'END' +bin_PROGRAMS =3D foo bar +foo_SOURCES =3D foo.y +bar_SOURCES =3D bar.y +if COND +AM_YFLAGS =3D $(YFLAGS) +bar_YFLAGS =3D -v +endif COND +END + +: > ylwrap + +$ACLOCAL +AUTOMAKE_fails +grep "Makefile\.am:5:.*AM_YFLAGS.* defined conditionally" stderr +grep "Makefile\.am:6:.*bar_YFLAGS.* defined conditionally" stderr + +: diff --git a/tests/yflags-d-false-positives.test b/tests/yflags-d-false-pos= itives.test new file mode 100755 index 0000000..c3d5ecb =2D-- /dev/null +++ b/tests/yflags-d-false-positives.test @@ -0,0 +1,42 @@ +#! /bin/sh +# Copyright (C) 2011 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 for false positives in automake recognition of `-d' in YFLAGS. + +. ./defs || Exit 1 + +set -e + +cat >> configure.in <<'END' +AC_PROG_CC +AC_PROG_YACC +END + +$ACLOCAL + +cat > Makefile.am <<'END' +bin_PROGRAMS =3D zardoz foobar +zardoz_SOURCES =3D zardoz.y +foobar_SOURCES =3D foobar.y +AM_YFLAGS =3D -xd --d - d --output=3Dd +foobar_YFLAGS =3D - d $(foovar)-d -dd +END + +$AUTOMAKE -a +$EGREP '(foobar|zardoz)\.h.*:' Makefile.in && Exit 1 +$EGREP '(foobar|zardoz)\.h' Makefile.in | $FGREP -v '$(YLWRAP) ' && Exit 1 + +: diff --git a/tests/yflags-force-override.test b/tests/yflags-force-override= =2Etest new file mode 100755 index 0000000..0b0133e =2D-- /dev/null +++ b/tests/yflags-force-override.test @@ -0,0 +1,64 @@ +#! /bin/sh +# Copyright (C) 2011 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 can cope with definition of the $(YFLAGS) variable +# in Makefile.am (even if that is an extremely bad practice, because that +# variable is user-reserved). + +. ./defs || Exit 1 + +set -e + +cat >> configure.in <<'END' +AC_PROG_CC +AC_PROG_YACC +AC_OUTPUT +END + +cat > Makefile.am <<'END' +bin_PROGRAMS =3D foo +foo_SOURCES =3D foo.y +YFLAGS =3D -d -v +END + +cat > foo.y << 'END' +%{ +int yylex () { return 0; } +void yyerror (char *s) { return; } +int main () { return 0; } +%} +%% +foobar : 'f' 'o' 'o' 'b' 'a' 'r' {}; +END + +$ACLOCAL +$AUTOMAKE -a -Wno-gnu + +$EGREP '(foo|YFLAGS)' Makefile.in # for debugging +grep '^foo.h *:' Makefile.in + +$AUTOCONF +./configure + +$MAKE + +test -f foo.c +test -f foo.h +test -f foo.output + +$MAKE distcheck + +: diff --git a/tests/yflags-var-expand.test b/tests/yflags-var-expand.test new file mode 100755 index 0000000..1967be3 =2D-- /dev/null +++ b/tests/yflags-var-expand.test @@ -0,0 +1,63 @@ +#! /bin/sh +# Copyright (C) 2011 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 expand variables when looking for `-d' in YFLAGS; +# for example, the following is supposed to work: +# foo_flags =3D -d +# AM_YFLAGS =3D $(foo_flags) + +. ./defs || Exit 1 + +set -e + +cat >> configure.in <<'END' +AC_PROG_CC +AC_PROG_YACC +END + +$ACLOCAL + +cat > Makefile.am <<'END' +bin_PROGRAMS =3D foo bar +foo_SOURCES =3D foo.y +bar_SOURCES =3D bar.y +my_YFLAGS =3D -x +AM_YFLAGS =3D $(my_YFLAGS:x=3Dd) +bar_YFLAGS =3D $(AM_YFLAGS) +END + +$AUTOMAKE -a + +$EGREP '(foo|bar|YFLAGS)' Makefile.in # for debugging +grep '^foo.h *:' Makefile.in +grep '^bar-bar.h *:' Makefile.in + +cat > Makefile.am <<'END' +AUTOMAKE_OPTIONS =3D -Wno-gnu +bin_PROGRAMS =3D zardoz +zardoz_SOURCES =3D parser.y +my_YFLAGS =3D $(my_YFLAGS_1) +my_YFLAGS +=3D $(my_YFLAGS_2) +my_YFLAGS_2 =3D -d +YFLAGS =3D $(my_YFLAGS) +END + +$AUTOMAKE + +$EGREP 'parser|YFLAGS' Makefile.in # for debugging +grep '^parser.h *:' Makefile.in + +: =2D-=20 1.7.2.3 --Boundary-00=_Mj5JNwcNGi/Zkm0 Content-Type: text/x-patch; charset="us-ascii"; name="0002-yacc-support-variable-expansions-in-YFLAGS-definitio.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline; filename="0002-yacc-support-variable-expansions-in-YFLAGS-definitio.patch" =46rom 312acec17badbf428abf3961e081004c721b5323 Mon Sep 17 00:00:00 2001 =46rom: Stefano Lattarini Date: Fri, 7 Jan 2011 21:52:56 +0100 Subject: [PATCH 2/2] yacc: support variable expansions in *YFLAGS definitio= n. This commit fixes automake bug#7800. * automake.in (lang_yacc_target_hook): Use 'value_as_list_recursive' instead of 'variable_value' to get the value of *YFLAGS variables. Related changes. ($DASH_D_PATTERN): Removed as obsolete. * tests/Makefile.am (XFAIL_TESTS): Remove yflags-var-expand.test. * tests/yacc-clean.test: Remove a now-useless workaround. * NEWS: Update. =2D-- ChangeLog | 12 ++++++++++++ NEWS | 6 ++++++ automake.in | 15 ++++++++------- tests/Makefile.am | 1 - tests/Makefile.in | 1 - tests/yacc-clean.test | 4 ---- 6 files changed, 26 insertions(+), 13 deletions(-) diff --git a/ChangeLog b/ChangeLog index 143109b..316ea61 100644 =2D-- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,17 @@ 2011-01-07 Stefano Lattarini =20 + yacc: support variable expansions in *YFLAGS definition. + This change fixes automake bug#7800. + * automake.in (lang_yacc_target_hook): Use 'value_as_list_recursive' + instead of 'variable_value' to get the value of *YFLAGS variables. + Related changes. + ($DASH_D_PATTERN): Removed as obsolete. + * tests/Makefile.am (XFAIL_TESTS): Remove yflags-var-expand.test. + * tests/yacc-clean.test: Remove a now-useless workaround. + * NEWS: Update. + +2011-01-07 Stefano Lattarini + tests: more on *YFLAGS support * tests/yflags-var-expand.test: New test, still xfailing. It exposes automake bug#7800 -- "automake fails to honor `-d' in diff --git a/NEWS b/NEWS index 0575935..1c489fc 100644 =2D-- a/NEWS +++ b/NEWS @@ -56,6 +56,12 @@ Bugs fixed in 1.11.0a: - The code for automatic dependency tracking works around a Solaris make bug triggered by sources containing repeated slashes when the `subdir-objects' option was used. + + - Automake is now smart enough to detect the presence of the `-d' flag + in the various `*YFLAGS' variables even when their definitions involve + indirections through other variables, such as in: + foo_opts =3D -d + AM_YFLAGS =3D $(foo_opts) =0C New in 1.11: =20 diff --git a/automake.in b/automake.in index b97d4a6..2bffe48 100755 =2D-- a/automake.in +++ b/automake.in @@ -208,8 +208,6 @@ my $INCLUDE_PATTERN =3D ('^include\s+' . '|(\$\(srcdir\)/' . $PATH_PATTERN . ')' . '|([^/\$]' . $PATH_PATTERN . '))\s*(#.*)?' . "\$"); =20 =2D# Match `-d' as a command-line argument in a string. =2Dmy $DASH_D_PATTERN =3D "(^|\\s)-d(\\s|\$)"; # Directories installed during 'install-exec' phase. my $EXEC_DIR_PATTERN =3D '^(?:bin|sbin|libexec|sysconf|localstate|lib|pkglib|.*exec.*)' . "\$"; @@ -6063,11 +6061,14 @@ sub lang_yacc_target_hook { my ($self, $aggregate, $output, $input, %transform) =3D @_; =20 =2D my $flag =3D $aggregate . "_YFLAGS"; =2D my $flagvar =3D var $flag; =2D my $YFLAGSvar =3D var 'YFLAGS'; =2D if (($flagvar && $flagvar->variable_value =3D~ /$DASH_D_PATTERN/o) =2D || ($YFLAGSvar && $YFLAGSvar->variable_value =3D~ /$DASH_D_PATTERN/o)) + my $flagvar =3D var ($aggregate . "_YFLAGS"); + my $YFLAGSvar =3D var ('YFLAGS'); + # We cannot work reliably with conditionally-defined YFLAGS. + $flagvar->check_defined_unconditionally if $flagvar; + $YFLAGSvar->check_defined_unconditionally if $YFLAGSvar; + my @flags =3D $flagvar ? $flagvar->value_as_list_recursive : (); + my @YFLAGS =3D $YFLAGSvar ? $YFLAGSvar->value_as_list_recursive : (); + if (grep (/^-d$/, @flags) || grep (/^-d$/, @YFLAGS)) { (my $output_base =3D $output) =3D~ s/$KNOWN_EXTENSIONS_PATTERN$//; my $header =3D $output_base . '.h'; diff --git a/tests/Makefile.am b/tests/Makefile.am index 0caa8d2..b4b2576 100644 =2D-- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -21,7 +21,6 @@ all.test \ auxdir2.test \ cond17.test \ gcj6.test \ =2Dyflags-var-expand.test \ txinfo5.test =20 include $(srcdir)/parallel-tests.am diff --git a/tests/Makefile.in b/tests/Makefile.in index 94fd7b2..586a2a0 100644 =2D-- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -277,7 +277,6 @@ all.test \ auxdir2.test \ cond17.test \ gcj6.test \ =2Dyflags-var-expand.test \ txinfo5.test =20 parallel_tests =3D \ diff --git a/tests/yacc-clean.test b/tests/yacc-clean.test index a8df065..009bf97 100755 =2D-- a/tests/yacc-clean.test +++ b/tests/yacc-clean.test @@ -62,10 +62,6 @@ END cat > sub2/Makefile.am << 'END' include $(top_srcdir)/sub1/Makefile.am AM_YFLAGS =3D -d =2D## FIXME: these apparently redundant definitions are required to =2D## work around automake bug#7800. =2Dbar_YFLAGS +=3D -d =2Dqux_YFLAGS +=3D -d END =20 cat > sub1/parse.y << 'END' =2D-=20 1.7.2.3 --Boundary-00=_Mj5JNwcNGi/Zkm0-- From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 18:16:56 2011 Received: (at control) by debbugs.gnu.org; 7 Jan 2011 23:16:56 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbLYF-00071U-SN for submit@debbugs.gnu.org; Fri, 07 Jan 2011 18:16:56 -0500 Received: from mail-fx0-f44.google.com ([209.85.161.44]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbLYD-00071I-KJ for control@debbugs.gnu.org; Fri, 07 Jan 2011 18:16:54 -0500 Received: by fxm9 with SMTP id 9so16894062fxm.3 for ; Fri, 07 Jan 2011 15:24:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:mime-version:content-type:content-transfer-encoding :message-id; bh=+XbMuBVfe77Pfy/SycrQCLTtK8ihMkkZrIfS4+Ojgwk=; b=KGSY4SYvs9OhANpogz37ZJ6vyzY0INFH23SOI3kXLt0rY1OvZx0y/NF9b6Cr/nGX/x 9canAlQ1esqTwcktl3ZkyNVMkfVSE1S6dOoD8sMU/p3ZLQlOD9mNqCjCzQZpDSx/+aKG 6femgf7DbTMrKc7TdRyfeUYkbBuGjuYne/M/g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:mime-version:content-type :content-transfer-encoding:message-id; b=NmEj7iJ6/hHelHLNDmSi6R5j3ElZyZpWDo097/BHuIW+7t2i9F7JL9rj100ia4mmvC 0ALLqx3kMymbMC3b6/3Nt8HYKcXK0KlVssax3pMk6WvqLlBFgQFlQYmNrggf2OagrpBG 6U4YYECBcnt4C88PVXj7ovN9I4DazTnRPXog8= Received: by 10.223.118.136 with SMTP id v8mr311783faq.90.1294442650971; Fri, 07 Jan 2011 15:24:10 -0800 (PST) Received: from bigio.localnet (host177-52-dynamic.48-82-r.retail.telecomitalia.it [82.48.52.177]) by mx.google.com with ESMTPS id n3sm6304783faa.5.2011.01.07.15.24.09 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 07 Jan 2011 15:24:10 -0800 (PST) From: Stefano Lattarini To: control@debbugs.gnu.org Subject: bug#7800 Date: Sat, 8 Jan 2011 00:23:57 +0100 User-Agent: KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <201101080023.57963.stefano.lattarini@gmail.com> X-Spam-Score: -3.6 (---) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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: -3.6 (---) tags 7800 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 22:18:59 2011 Received: (at 7800) by debbugs.gnu.org; 8 Jan 2011 03:18:59 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbPKV-0004Tr-4i for submit@debbugs.gnu.org; Fri, 07 Jan 2011 22:18:59 -0500 Received: from mout5.freenet.de ([195.4.92.95]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbPKS-0004Tf-OA for 7800@debbugs.gnu.org; Fri, 07 Jan 2011 22:18:57 -0500 Received: from [195.4.92.24] (helo=14.mx.freenet.de) by mout5.freenet.de with esmtpa (ID ralf.corsepius@freenet.de) (port 25) (Exim 4.72 #3) id 1PbPRW-0005wq-Uy; Sat, 08 Jan 2011 04:26:14 +0100 Received: from hsi-kbw-078-043-059-079.hsi4.kabel-badenwuerttemberg.de ([78.43.59.79]:59513 helo=[192.168.1.104]) by 14.mx.freenet.de with esmtpsa (ID ralf.corsepius@freenet.de) (TLSv1:CAMELLIA256-SHA:256) (port 587) (Exim 4.72 #3) id 1PbPRW-0006mA-QH; Sat, 08 Jan 2011 04:26:14 +0100 Message-ID: <4D27D953.5030306@rtems.org> Date: Sat, 08 Jan 2011 04:26:11 +0100 From: Ralf Corsepius User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Thunderbird/3.1.7 MIME-Version: 1.0 To: Ralf Wildenhues Subject: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved References: <201101071536.44228.stefano.lattarini@gmail.com> <4D2744E6.3000005@rtems.org> <20110107185319.GH12928@gmx.de> In-Reply-To: <20110107185319.GH12928@gmx.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 7800 Cc: 7800@debbugs.gnu.org, Stefano Lattarini X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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 (--) On 01/07/2011 07:53 PM, Ralf Wildenhues wrote: > Hello Ralf, > > * Ralf Corsepius wrote on Fri, Jan 07, 2011 at 05:52:54PM CET: >> On 01/07/2011 03:36 PM, Stefano Lattarini wrote: >>> Currently, automake is not smart enough to resolve variable expansions >>> in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. >> This once used to work >> >> => regression. > Please, if you make such a statement, include more details: whether you > know of an Automake version where this used to work, or have code > examples where it did (including a pointer to the code), or have just > tried the sample code from the PR. Well, I would have to dig out ca. 10 years old works, which had exploited this. I also recall having reported issues with automake's "yacc -d" handling to Akim when he was maintaining automake and him having worked on it. I also recall me having abandoned using automake's YACC rules in my works, because it repeatedly had been broken during automake's history. > If you don't have more details, then > please also state so; even stating some guess is better than not > providing any data at all. With just the above, it is hard to judge. Ralf From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 13:17:28 2011 Received: (at 7800) by debbugs.gnu.org; 8 Jan 2011 18:17:29 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PbdM0-00086W-9z for submit@debbugs.gnu.org; Sat, 08 Jan 2011 13:17:28 -0500 Received: from mailout-de.gmx.net ([213.165.64.22] helo=mail.gmx.net) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1PbdLx-00086L-9q for 7800@debbugs.gnu.org; Sat, 08 Jan 2011 13:17:26 -0500 Received: (qmail invoked by alias); 08 Jan 2011 18:24:44 -0000 Received: from xdsl-78-34-215-107.netcologne.de (EHLO localhost.localdomain) [78.34.215.107] by mail.gmx.net (mp070) with SMTP; 08 Jan 2011 19:24:44 +0100 X-Authenticated: #13673931 X-Provags-ID: V01U2FsdGVkX19DObEzuwVDBc3/E4kG2B2o15pkZFPMvpu09brCt+ Fqjsa49UV8GIFM Received: from ralf by localhost.localdomain with local (Exim 4.69) (envelope-from ) id 1PbdT1-0002xU-MW; Sat, 08 Jan 2011 19:24:43 +0100 Date: Sat, 8 Jan 2011 19:24:43 +0100 From: Ralf Wildenhues To: Ralf Corsepius Subject: Re: bug#7800: automake fails to honor `-d' in AM_YFLAGS when variable expansions are involved Message-ID: <20110108182443.GJ4786@gmx.de> References: <201101071536.44228.stefano.lattarini@gmail.com> <4D2744E6.3000005@rtems.org> <20110107185319.GH12928@gmx.de> <4D27D953.5030306@rtems.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D27D953.5030306@rtems.org> Organization: Institute for Numerical Simulation, University of Bonn User-Agent: Mutt/1.5.20 (2010-08-04) X-Y-GMX-Trusted: 0 X-Spam-Score: -2.9 (--) X-Debbugs-Envelope-To: 7800 Cc: 7800@debbugs.gnu.org, Stefano Lattarini X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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.9 (--) * Ralf Corsepius wrote on Sat, Jan 08, 2011 at 04:26:11AM CET: > On 01/07/2011 07:53 PM, Ralf Wildenhues wrote: > >* Ralf Corsepius wrote on Fri, Jan 07, 2011 at 05:52:54PM CET: > >>On 01/07/2011 03:36 PM, Stefano Lattarini wrote: > >>>Currently, automake is not smart enough to resolve variable expansions > >>>in AM_YFLAGS (or foo_YFLAGS) when scanning them for the `-d' flag. > >>This once used to work > >> > >>=> regression. > >Please, if you make such a statement, include more details: whether you > >know of an Automake version where this used to work, or have code > >examples where it did (including a pointer to the code), or have just > >tried the sample code from the PR. > Well, I would have to dig out ca. 10 years old works, which had > exploited this. > > I also recall having reported issues with automake's "yacc -d" > handling to Akim when he was maintaining automake and him having > worked on it. > > I also recall me having abandoned using automake's YACC rules in my > works, because it repeatedly had been broken during automake's > history. Thanks. All of the above information would have made the first post more helpful already. For example, it is very helpful to know whether something is a recent regression or not; not only for classifying the severity, but also checking for other similar glitches that may have happened at the same time. Cheers, Ralf From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 09 10:22:24 2011 Received: (at 7800-done) by debbugs.gnu.org; 9 Jan 2011 15:22:24 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Pbx68-0005Tq-Ly for submit@debbugs.gnu.org; Sun, 09 Jan 2011 10:22:24 -0500 Received: from mail-wy0-f172.google.com ([74.125.82.172]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Pbx66-0005Te-Qy for 7800-done@debbugs.gnu.org; Sun, 09 Jan 2011 10:22:23 -0500 Received: by wyf23 with SMTP id 23so19543466wyf.3 for <7800-done@debbugs.gnu.org>; Sun, 09 Jan 2011 07:29:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:message-id :content-type:content-transfer-encoding; bh=bvKF9xbT85kzNIlhcLm9lSqYs8uh3fAiTjZgtyK5UUw=; b=ll639ADxdavfo3G7JhdbkVFewyYlssrSZlM3rw0nvfcDvD8drOHqb68c6yd7CgmXrt v0f171mKEEOj8byzCJRxg7PAdkUFtykGZEtb/LXFCscLFu7hGH5t/e0v9SJp6LJv0h1M XxutpFkkOPNeVY/obP1b91YMW4HIir5AWbsv8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:message-id:content-type:content-transfer-encoding; b=e2mQrMaNv/z0L9Oh9D56f/V2tMEE/vUSBzZVZZOCvLBMOUowL+WXVXQvWBdkti+uXa UeDVVGFFIzsD66l1OQrWDPB8vxyrdCWU2S6ZqRQNqXvS3+jtN91Rw7uFhjDUneZBOx93 SkOOExyNXYHnKEDnupDun8v/iX2ZaGvB3us7w= Received: by 10.227.132.206 with SMTP id c14mr1763130wbt.124.1294586911931; Sun, 09 Jan 2011 07:28:31 -0800 (PST) Received: from bigio.localnet (host26-9-dynamic.52-82-r.retail.telecomitalia.it [82.52.9.26]) by mx.google.com with ESMTPS id 11sm19320274wbi.18.2011.01.09.07.28.30 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 09 Jan 2011 07:28:31 -0800 (PST) From: Stefano Lattarini To: Ralf Wildenhues Subject: Re: [PATCHES] yacc: support variable expansions in *YFLAGS definition Date: Sun, 9 Jan 2011 16:28:06 +0100 User-Agent: KMail/1.13.3 (Linux/2.6.30-2-686; KDE/4.4.4; i686; ; ) References: <201101071536.44228.stefano.lattarini@gmail.com> <20110107182118.GC12928@gmx.de> <201101072350.53021.stefano.lattarini@gmail.com> In-Reply-To: <201101072350.53021.stefano.lattarini@gmail.com> MIME-Version: 1.0 Message-Id: <201101091628.07298.stefano.lattarini@gmail.com> Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Spam-Score: -3.9 (---) X-Debbugs-Envelope-To: 7800-done Cc: 7800-done@debbugs.gnu.org, automake-patches@gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 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: -3.9 (---) Reference: Both patches (with nits addressed) merged to master, and pushed. This should fix automake bug#7800. Regards, Stefano From unknown Sat Sep 06 00:11:38 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 07 Feb 2011 12:24:04 +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