xref: /OK3568_Linux_fs/buildroot/package/libtool/libtool.mk (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun################################################################################
2*4882a593Smuzhiyun#
3*4882a593Smuzhiyun# libtool
4*4882a593Smuzhiyun#
5*4882a593Smuzhiyun################################################################################
6*4882a593Smuzhiyun
7*4882a593SmuzhiyunLIBTOOL_VERSION = 2.4.6
8*4882a593SmuzhiyunLIBTOOL_SOURCE = libtool-$(LIBTOOL_VERSION).tar.xz
9*4882a593SmuzhiyunLIBTOOL_SITE = $(BR2_GNU_MIRROR)/libtool
10*4882a593SmuzhiyunLIBTOOL_CPE_ID_VENDOR = gnu
11*4882a593Smuzhiyun
12*4882a593Smuzhiyun# For the target variant, we only want to build/install libltdl
13*4882a593SmuzhiyunLIBTOOL_SUBDIR = libltdl
14*4882a593SmuzhiyunHOST_LIBTOOL_SUBDIR = .
15*4882a593Smuzhiyun
16*4882a593SmuzhiyunLIBTOOL_INSTALL_STAGING = YES
17*4882a593Smuzhiyun
18*4882a593SmuzhiyunLIBTOOL_CONF_OPTS = --enable-ltdl-install
19*4882a593Smuzhiyun
20*4882a593SmuzhiyunLIBTOOL_DEPENDENCIES = host-m4
21*4882a593SmuzhiyunHOST_LIBTOOL_DEPENDENCIES = host-m4
22*4882a593Smuzhiyun
23*4882a593SmuzhiyunLIBTOOL_LICENSE = LGPL-2.1+
24*4882a593SmuzhiyunLIBTOOL_LICENSE_FILES = $(LIBTOOL_SUBDIR)/COPYING.LIB
25*4882a593SmuzhiyunHOST_LIBTOOL_LICENSE = GPL-2.0+ (libtool), LGPL-2.1+ (libltdl)
26*4882a593SmuzhiyunHOST_LIBTOOL_LICENSE_FILES = COPYING $(LIBTOOL_SUBDIR)/COPYING.LIB
27*4882a593Smuzhiyun
28*4882a593SmuzhiyunHOST_LIBTOOL_CONF_ENV = MAKEINFO=true
29*4882a593SmuzhiyunHOST_LIBTOOL_LIBTOOL_PATCH = NO
30*4882a593Smuzhiyun
31*4882a593Smuzhiyun# We have a patch that affects libtool.m4, which triggers an autoreconf
32*4882a593Smuzhiyun# in the build step. Normally we would set AUTORECONF = YES, but this
33*4882a593Smuzhiyun# doesn't work for host-libtool because that creates a circular
34*4882a593Smuzhiyun# dependency. Instead, touch the generated files so autoreconf is not
35*4882a593Smuzhiyun# triggered in the build step. Note that aclocal.m4 has to be touched
36*4882a593Smuzhiyun# first since the rest depends on it. Note that we don't need the changes
37*4882a593Smuzhiyun# in libtool.m4 in our configure script, because we're not actually
38*4882a593Smuzhiyun# running it on the target.
39*4882a593Smuzhiyun# For the target, we would normally be able to use AUTORECONF, but it
40*4882a593Smuzhiyun# fails on libltdl/Makefile.inc. Rather than trying to fix that failure,
41*4882a593Smuzhiyun# just use the same hack as on the host.
42*4882a593Smuzhiyundefine LIBTOOL_AVOID_AUTORECONF_HOOK
43*4882a593Smuzhiyun	find $(@D) -name aclocal.m4 -exec touch '{}' \;
44*4882a593Smuzhiyun	find $(@D) -name config-h.in -exec touch '{}' \;
45*4882a593Smuzhiyun	find $(@D) -name configure -exec touch '{}' \;
46*4882a593Smuzhiyun	find $(@D) -name Makefile.in -exec touch '{}' \;
47*4882a593Smuzhiyunendef
48*4882a593SmuzhiyunLIBTOOL_PRE_CONFIGURE_HOOKS += LIBTOOL_AVOID_AUTORECONF_HOOK
49*4882a593SmuzhiyunHOST_LIBTOOL_PRE_CONFIGURE_HOOKS += LIBTOOL_AVOID_AUTORECONF_HOOK
50*4882a593Smuzhiyun
51*4882a593Smuzhiyun$(eval $(autotools-package))
52*4882a593Smuzhiyun$(eval $(host-autotools-package))
53*4882a593Smuzhiyun
54*4882a593Smuzhiyun# variables used by other packages
55*4882a593SmuzhiyunLIBTOOL = $(HOST_DIR)/bin/libtool
56*4882a593SmuzhiyunLIBTOOLIZE = $(HOST_DIR)/bin/libtoolize
57