summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMathieu Lirzin <mthl@gnu.org>2017-08-30 23:45:49 +0200
committerMathieu Lirzin <mthl@gnu.org>2017-08-31 00:34:30 +0200
commit99cf7ca5ed35afa9552a3a2429963130700a0fde (patch)
treeb1d848919fd10e7df2589e9dd31d0def449071dc
parentab2d33e635f85f8f215b7e8f14571ec6360d2243 (diff)
downloadautomake-99cf7ca5ed35afa9552a3a2429963130700a0fde.tar.gz
build: Generate versioned scripts at make time
* configure.ac: Don't generate 'bin/aclocal-${APIVERSION}' and 'bin/automake-${APIVERSION}'. * bin/wrap-aclocal.in: Delete. * bin/wrap-automake.in: Likewise. * bin/Makefile.inc (%D%/automake-$(APIVERSION)) (%D%/aclocal-$(APIVERSION)): New targets. (CLEANFILES): Add them.
-rw-r--r--bin/Makefile.inc15
-rw-r--r--bin/wrap-aclocal.in19
-rw-r--r--bin/wrap-automake.in19
-rw-r--r--configure.ac8
4 files changed, 13 insertions, 48 deletions
diff --git a/bin/Makefile.inc b/bin/Makefile.inc
index 69a744d87..62dd483d9 100644
--- a/bin/Makefile.inc
+++ b/bin/Makefile.inc
@@ -18,12 +18,15 @@
## ----------------------------------- ##
bin_SCRIPTS = %D%/automake %D%/aclocal
-CLEANFILES += $(bin_SCRIPTS)
-
nodist_noinst_SCRIPTS += \
%D%/aclocal-$(APIVERSION) \
%D%/automake-$(APIVERSION)
+CLEANFILES += \
+ $(bin_SCRIPTS) \
+ %D%/aclocal-$(APIVERSION) \
+ %D%/automake-$(APIVERSION)
+
# Used by maintainer checks and such.
automake_in = $(srcdir)/%D%/automake.in
aclocal_in = $(srcdir)/%D%/aclocal.in
@@ -72,4 +75,12 @@ uninstall-hook:
&& chmod a+x,a-w $@-t && mv -f $@-t $@
EXTRA_DIST += %D%/gen-perl-protos
+%D%/aclocal-$(APIVERSION): %D%/aclocal
+ $(AM_V_GEN) rm -f $@; \
+ $(LN) %D%/aclocal $@
+
+%D%/automake-$(APIVERSION): %D%/automake
+ $(AM_V_GEN) rm -f $@; \
+ $(LN) %D%/automake $@
+
# vim: ft=automake noet
diff --git a/bin/wrap-aclocal.in b/bin/wrap-aclocal.in
deleted file mode 100644
index e6e4782d2..000000000
--- a/bin/wrap-aclocal.in
+++ /dev/null
@@ -1,19 +0,0 @@
-#!@PERL@ -w
-# @configure_input@
-
-# Copyright (C) 2012-2017 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 <http://www.gnu.org/licenses/>.
-
-require '@abs_top_builddir@/bin/aclocal';
diff --git a/bin/wrap-automake.in b/bin/wrap-automake.in
deleted file mode 100644
index 09b1b30f8..000000000
--- a/bin/wrap-automake.in
+++ /dev/null
@@ -1,19 +0,0 @@
-#!@PERL@ -w
-# @configure_input@
-
-# Copyright (C) 2012-2017 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 <http://www.gnu.org/licenses/>.
-
-require '@abs_top_builddir@/bin/automake';
diff --git a/configure.ac b/configure.ac
index 7c8ecb4af..7f91f9609 100644
--- a/configure.ac
+++ b/configure.ac
@@ -579,15 +579,7 @@ AC_SUBST([EXEEXT])
AC_CONFIG_FILES([Makefile])
AC_CONFIG_LINKS([GNUmakefile:GNUmakefile])
-
AC_CONFIG_FILES([pre-inst-env], [chmod +x pre-inst-env])
-AC_CONFIG_FILES([bin/aclocal-${APIVERSION}:bin/wrap-aclocal.in],
- [chmod +x bin/aclocal-${APIVERSION}],
- [APIVERSION=$APIVERSION])
-AC_CONFIG_FILES([bin/automake-${APIVERSION}:bin/wrap-automake.in],
- [chmod +x bin/automake-${APIVERSION}],
- [APIVERSION=$APIVERSION])
-
AC_OUTPUT
# Inform the user if this version of automake is a beta release or