aboutsummaryrefslogtreecommitdiffstats
path: root/tools/automake/Makefile
diff options
context:
space:
mode:
authorMichael Pratt <mcpratt@pm.me>2022-09-02 14:51:48 -0400
committerHauke Mehrtens <hauke@hauke-m.de>2023-03-13 22:53:41 +0100
commita3cf796e7731fb7ce657017ad34e93acf35b038a (patch)
tree2b87efd620f88a82c58c34d9b5515a0152ebb7b0 /tools/automake/Makefile
parent8d0ff17ec9907b1383644793884c2b50598aafea (diff)
downloadupstream-a3cf796e7731fb7ce657017ad34e93acf35b038a.tar.gz
upstream-a3cf796e7731fb7ce657017ad34e93acf35b038a.tar.bz2
upstream-a3cf796e7731fb7ce657017ad34e93acf35b038a.zip
tools/automake: use make variable to generate aclocal symlinks
Instead of having a somewhat random list of aclocal symlinks which are named with the API versioning scheme, install a symlink for every API version since 1.11 (the first release after Automake was moved to git) using the API version number from the version of automake that is currently in openwrt. Automake API versioning does not include the patch level number. Signed-off-by: Michael Pratt <mcpratt@pm.me>
Diffstat (limited to 'tools/automake/Makefile')
-rw-r--r--tools/automake/Makefile13
1 files changed, 8 insertions, 5 deletions
diff --git a/tools/automake/Makefile b/tools/automake/Makefile
index 3a05cc90f8..246e1814b7 100644
--- a/tools/automake/Makefile
+++ b/tools/automake/Makefile
@@ -9,6 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=automake
PKG_CPE_ID:=cpe:/a:gnu:automake
PKG_VERSION:=1.15.1
+PKG_API_VERSION:=$(word 2,$(subst ., ,$(PKG_VERSION)))
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=@GNU/automake
@@ -34,11 +35,13 @@ define Host/Install
$(call Host/Compile/Default,install)
mv $(STAGING_DIR_HOST)/bin/aclocal $(STAGING_DIR_HOST)/bin/aclocal.real
$(INSTALL_BIN) ./files/aclocal $(STAGING_DIR_HOST)/bin
- ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.9
- ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.10
- ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.11
- ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.11.6
- ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.15
+ ( \
+ api=$(PKG_API_VERSION); \
+ while [ "$$$$api" -ge 11 ]; do \
+ ln -sf aclocal "$(STAGING_DIR_HOST)/bin/aclocal-1.$$$$api"; \
+ api=$$$$(($$$$api - 1)); \
+ done; \
+ )
endef
define Host/Uninstall