Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
To: Tom Tromey <tromey@redhat.com>
Cc: binutils@sourceware.org, gdb-patches@sourceware.org
Subject: Re: Update rebuild rules in non-automake directories.
Date: Thu, 30 Jul 2009 21:27:00 -0000	[thread overview]
Message-ID: <20090730210952.GD24465@gmx.de> (raw)
In-Reply-To: <m34osw1vg9.fsf@fleche.redhat.com>

* 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.Wildenhues@gmx.de>
> 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  <Ralf.Wildenhues@gmx.de>

	* 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!



  parent reply	other threads:[~2009-07-30 21:10 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20090628183334.GA5401@gmx.de>
2009-07-28 18:54 ` Ralf Wildenhues
2009-07-28 19:51   ` Paolo Bonzini
2009-07-28 21:35   ` Tom Tromey
2009-07-29  3:09     ` Samuel Bronson
2009-07-29  5:31       ` Tom Tromey
2009-07-29 16:15       ` Ralf Wildenhues
2009-07-29 18:35         ` Samuel Bronson
2009-07-29 18:37         ` Tom Tromey
2009-07-30 21:27     ` Ralf Wildenhues [this message]
     [not found]     ` <20090730210952.GD24465__15749.4424529888$1248988226$gmane$org@gmx.de>
2009-07-30 21:30       ` Tom Tromey
2009-07-29 15:16   ` Ben Elliston
2009-08-26 16:29   ` Jan Kratochvil
2009-08-26 16:54     ` Ralf Wildenhues
2009-08-26 17:10       ` Jan Kratochvil
2009-08-26 17:51         ` Ralf Wildenhues
2009-08-26 17:57           ` Eli Zaretskii
2009-08-26 19:13           ` Jan Kratochvil
2009-08-31 20:42         ` obtaining configure args from config.status (was: Update rebuild rules in non-automake directories.) Ralf Wildenhues
2009-09-01  1:10           ` obtaining configure args from config.status Paolo Bonzini
2009-09-06 18:15           ` obtaining configure args from config.status (was: Update rebuild rules in non-automake directories.) Ralf Wildenhues
2009-09-08 18:37             ` obtaining configure args from config.status Tom Tromey
2009-09-08 16:28           ` Jan Kratochvil
2009-09-08 18:26             ` Ralf Wildenhues
2009-09-08 18:38               ` Tom Tromey
2009-09-08 18:51                 ` Ralf Wildenhues

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090730210952.GD24465@gmx.de \
    --to=ralf.wildenhues@gmx.de \
    --cc=binutils@sourceware.org \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox