From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32130 invoked by alias); 30 Jul 2009 21:10:08 -0000 Received: (qmail 32101 invoked by uid 22791); 30 Jul 2009 21:10:06 -0000 X-SWARE-Spam-Status: No, hits=-0.3 required=5.0 tests=AWL,BAYES_00,HK_OBFDOM,J_CHICKENPOX_52,J_CHICKENPOX_66,J_CHICKENPOX_92,J_CHICKENPOX_93,SPF_PASS X-Spam-Check-By: sourceware.org Received: from mail.gmx.net (HELO mail.gmx.net) (213.165.64.20) by sourceware.org (qpsmtpd/0.43rc1) with SMTP; Thu, 30 Jul 2009 21:09:58 +0000 Received: (qmail invoked by alias); 30 Jul 2009 21:09:53 -0000 Received: from xdsl-87-78-161-251.netcologne.de (EHLO localhost.localdomain) [87.78.161.251] by mail.gmx.net (mp070) with SMTP; 30 Jul 2009 23:09:53 +0200 Received: from ralf by localhost.localdomain with local (Exim 4.69) (envelope-from ) id 1MWcsq-00084u-KL; Thu, 30 Jul 2009 23:09:52 +0200 Date: Thu, 30 Jul 2009 21:27:00 -0000 From: Ralf Wildenhues To: Tom Tromey Cc: binutils@sourceware.org, gdb-patches@sourceware.org Subject: Re: Update rebuild rules in non-automake directories. Message-ID: <20090730210952.GD24465@gmx.de> References: <20090628183334.GA5401@gmx.de> <20090728181748.GA3134@gmx.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-15) Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2009-07/txt/msg00751.txt.bz2 * Tom Tromey wrote on Tue, Jul 28, 2009 at 09:03:34PM CEST: > >>>>> "Ralf" == Ralf Wildenhues writes: > > Ralf> gdb/ChangeLog: > Ralf> 2009-07-28 Ralf Wildenhues > Ralf> * Makefile.in (ACLOCAL, ACLOCAL_AMFLAGS, aclocal_m4_deps): > Ralf> New variables. > Ralf> ($(srcdir)/aclocal.m4, am--refresh): New rules. > > It seems a little odd to have a rule to rebuild aclocal.m4 when there is > no rule to rebuild configure. Are you planning to add that? (I don't > think this affects whether the patch is ok -- it is still an improvement > over the present situation.) Respin of the gdb part including rebuild rules for configure and config.in. FWIW, the $(srcdir)/ prefixes before files that are mentioned both as targets as well as as prerequisites are needed to let some BSD make implementations find them portably. Anyway the whole thing is pretty much copied from Automake rules. OK? As to Paolo's comment, I didn't see how to easily bring autom4te output into the mix, and also don't trust distros to have autom4te versioned as consistently as some have autoconf and autoheader. Thanks, Ralf gdb/ChangeLog: 2009-07-30 Ralf Wildenhues * Makefile.in (ACLOCAL, ACLOCAL_AMFLAGS, aclocal_m4_deps) (AUTOCONF, configure_deps, AUTOHEADER): New variables. ($(srcdir)/aclocal.m4, $(srcdir)/configure, $(srcdir)/config.in) (am--refresh): New rules. (stamp-h, config.status): List config.in and configure including $(srcdir)/ prefix. Index: gdb/Makefile.in =================================================================== RCS file: /cvs/src/src/gdb/Makefile.in,v retrieving revision 1.1091 diff -u -r1.1091 Makefile.in --- gdb/Makefile.in 3 Jul 2009 12:06:35 -0000 1.1091 +++ gdb/Makefile.in 30 Jul 2009 21:01:54 -0000 @@ -1212,16 +1212,69 @@ $(SHELL) config.status config.h: stamp-h ; @true -stamp-h: config.in config.status +stamp-h: $(srcdir)/config.in config.status CONFIG_HEADERS=config.h:config.in \ CONFIG_COMMANDS="default depdir" \ CONFIG_FILES= \ CONFIG_LINKS= \ $(SHELL) config.status -config.status: configure configure.tgt configure.host +config.status: $(srcdir)/configure configure.tgt configure.host $(SHELL) config.status --recheck +ACLOCAL = aclocal +ACLOCAL_AMFLAGS = -I gnulib/m4 +aclocal_m4_deps = \ + configure.ac \ + gnulib/m4/extensions.m4 \ + gnulib/m4/gnulib-common.m4 \ + gnulib/m4/gnulib-comp.m4 \ + gnulib/m4/include_next.m4 \ + gnulib/m4/longlong.m4 \ + gnulib/m4/memchr.m4 \ + gnulib/m4/memcmp.m4 \ + gnulib/m4/memmem.m4 \ + gnulib/m4/onceonly_2_57.m4 \ + gnulib/m4/stdint.m4 \ + gnulib/m4/string_h.m4 \ + gnulib/m4/wchar.m4 \ + ../config/extensions.m4 \ + ../config/lead-dot.m4 \ + ../config/proginstall.m4 \ + ../bfd/bfd.m4 \ + ../config/acinclude.m4 \ + ../config/override.m4 \ + ../config/gettext-sister.m4 \ + ../config/lib-ld.m4 \ + ../config/lib-prefix.m4 \ + ../config/lib-link.m4 \ + ../config/acx.m4 \ + ../config/tcl.m4 \ + ../config/depstand.m4 \ + ../config/lcmessage.m4 \ + ../config/codeset.m4 + +$(srcdir)/aclocal.m4: @MAINTAINER_MODE_TRUE@ $(aclocal_m4_deps) + cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) + +AUTOCONF = autoconf +configure_deps = $(srcdir)/configure.ac $(srcdir)/aclocal.m4 +$(srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(configure_deps) + cd $(srcdir) && $(AUTOCONF) + +AUTOHEADER = autoheader +$(srcdir)/config.in: @MAINTAINER_MODE_TRUE@ $(configure_deps) + cd $(srcdir) && $(AUTOHEADER) + rm -f stamp-h + touch $@ + +# automatic rebuilding in automake-generated Makefiles requires +# this rule in the toplevel Makefile, which, with GNU make, causes +# the desired updates through the implicit regeneration of the Makefile +# and all of its prerequisites. +am--refresh: + @: + force: # Documentation!