]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Use a more general GNUmakefile.
authorJim Meyering <meyering@redhat.com>
Wed, 12 Mar 2008 12:14:44 +0000 (13:14 +0100)
committerJim Meyering <meyering@redhat.com>
Thu, 13 Mar 2008 21:16:52 +0000 (22:16 +0100)
* GNUmakefile: Sync from coreutils.
* Makefile.am (EXTRA_DIST): Add GNUmakefile.cfg.
* GNUmakefile.cfg: New file.

GNUmakefile
GNUmakefile.cfg [new file with mode: 0644]
Makefile.am

index e22015b86794910492b597f7c0a2d5c853b28acf..8bbd6c8fce65397dd57ae6d7cb1f6ca0d6d83a26 100644 (file)
@@ -38,14 +38,15 @@ ifeq ($(_have-Makefile),yes)
 # Make tar archive easier to reproduce.
 export TAR_OPTIONS = --owner=0 --group=0 --numeric-owner
 
-# Build with our own versions of these tools, when possible.
-export PATH = $(shell echo "`pwd`/tests:$$PATH")
-
 include Makefile
 
+# Some projects override e.g., _autoreconf here.
+-include $(srcdir)/GNUmakefile.cfg
+
+_autoreconf ?= autoreconf
+
 # Ensure that $(VERSION) is up to date for dist-related targets, but not
-# for others: rerunning autoconf and recompiling everything isn't cheap.
-# Remove the autoreconf-provided INSTALL, so that we regenerate it.
+# for others: rerunning autoreconf and recompiling everything isn't cheap.
 ifeq (0,$(MAKELEVEL))
   _is-dist-target = $(filter-out %clean, \
     $(filter dist% alpha beta major,$(MAKECMDGOALS)))
@@ -54,11 +55,7 @@ ifeq (0,$(MAKELEVEL))
                    $(srcdir)/.tarball-version)
     ifneq ($(_curr-ver),$(VERSION))
       $(info INFO: running autoreconf for new version string: $(_curr-ver))
-      _dummy := $(shell                                \
-       cd $(srcdir)                            \
-         && rm -rf autom4te.cache              \
-         && autoreconf -i -v                   \
-         && rm -f INSTALL)
+      _dummy := $(shell cd $(srcdir) && rm -rf autom4te.cache && $(_autoreconf)))
     endif
   endif
 endif
diff --git a/GNUmakefile.cfg b/GNUmakefile.cfg
new file mode 100644 (file)
index 0000000..be213f4
--- /dev/null
@@ -0,0 +1,7 @@
+# This file is '-include'd into GNUmakefile.
+
+# Build with our own versions of these tools, when possible.
+export PATH = $(shell echo "`pwd`/tests:$$PATH")
+
+# Remove the autoreconf-provided INSTALL, so that we regenerate it.
+_autoreconf = autoreconf -i -v && rm -f INSTALL
index 57e750947ed1fff4272c0caf5ea5d3e43a83769d..9abb7ca6f0f8db5a1b1635288649a8803ded3f8f 100644 (file)
@@ -25,7 +25,8 @@ ACLOCAL_AMFLAGS = -I m4
 
 EXTRA_DIST = ChangeLog.0 ChangeLog.1 ChangeLog.2 \
             BUGS \
-            GNUmakefile Makefile.maint Makefile.cfg \
+            GNUmakefile GNUmakefile.cfg \
+            Makefile.maint Makefile.cfg \
             build-aux/git-version-gen \
             config/announce-gen config/prev-version.txt