]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
build: Generate versioned scripts at make time
authorMathieu Lirzin <mthl@gnu.org>
Wed, 30 Aug 2017 21:45:49 +0000 (23:45 +0200)
committerMathieu Lirzin <mthl@gnu.org>
Wed, 30 Aug 2017 22:34:30 +0000 (00:34 +0200)
* 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.

bin/Makefile.inc
bin/wrap-aclocal.in [deleted file]
bin/wrap-automake.in [deleted file]
configure.ac

index 69a744d8714fd897a3112168d716bb3bc10ef57c..62dd483d909f97ca8200b8e5cc75215119e44f3a 100644 (file)
 ## ----------------------------------- ##
 
 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 (file)
index e6e4782..0000000
+++ /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 (file)
index 09b1b30..0000000
+++ /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';
index 7c8ecb4afe35eda8afff4cbaa1af25ff8227852d..7f91f9609b354e516948c7bd9ba3724c9a388c45 100644 (file)
@@ -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