Fresh pull from upstream
[librecmc/librecmc.git] / tools / automake / Makefile
1 #
2 # Copyright (C) 2006-2015 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 include $(TOPDIR)/rules.mk
8
9 PKG_NAME:=automake
10 PKG_VERSION:=1.15
11
12 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
13 PKG_SOURCE_URL:=@GNU/automake
14 PKG_HASH:=9908c75aabd49d13661d6dcb1bc382252d22cc77bf733a2d55e87f2aa2db8636
15
16 include $(INCLUDE_DIR)/host-build.mk
17
18 HOST_CONFIGURE_ARGS += \
19         --datarootdir=$(STAGING_DIR_HOST)/share \
20         --disable-silent-rules
21
22 HOST_CONFIGURE_VARS += \
23         PERL="/usr/bin/env perl" \
24         am_cv_prog_PERL_ithreads=no
25
26 define Host/Configure
27         (cd $(HOST_BUILD_DIR); $(AM_TOOL_PATHS) STAGING_DIR="" ./bootstrap.sh)
28         $(call Host/Configure/Default)
29 endef
30
31 define Host/Install
32         # remove old automake resources to avoid version conflicts
33         rm -rf $(STAGING_DIR_HOST)/share/aclocal-[0-9]*
34         rm -rf $(STAGING_DIR_HOST)/share/automake-[0-9]*
35         $(MAKE) -C $(HOST_BUILD_DIR) install
36         mv $(STAGING_DIR_HOST)/bin/aclocal $(STAGING_DIR_HOST)/bin/aclocal.real
37         $(INSTALL_BIN) ./files/aclocal $(STAGING_DIR_HOST)/bin
38         ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.9
39         ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.10
40         ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.11
41         ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.11.6
42         ln -sf aclocal $(STAGING_DIR_HOST)/bin/aclocal-1.15
43 endef
44
45 define Host/Clean
46         -$(MAKE) -C $(HOST_BUILD_DIR) uninstall
47         $(call Host/Clean/Default)
48 endef
49
50 $(eval $(call HostBuild))