1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
|
# $NetBSD: Makefile,v 1.4 2019/07/09 15:45:25 riastradh Exp $
# XXX This is kludgerific copypasta of devel/libtool-base/Makefile for
# cross-compilation. Please make it go away!
###########################################################################
###########################################################################
#
# HEADS UP! DO NOT CHANGE THE VERSION OR PKGREVISION WITHOUT READING THIS:
#
###########################################################################
###########################################################################
#
# This package is maintained specially in order to preserve pkgsrc
# specific OS changes that diverge from the "out of the box" libtool.
# In order to keep this package in a maintainable condition, the .m4 files
# must be manipulated in order to generate the patch-* files.
#
# See devel/libtool/patches/manual.README for instructions on how to make
# these patch files properly; otherwise your changes WILL be lost on the
# next libtool update.
#
# DO NOT MAKE CHANGES TO THESE FILES:
#
# patches/patch-build-aux_ltmain.sh
# patches/patch-configure
# patches/patch-libltdl_configure
#
# WITHOUT FOLLOWING THESE INSTRUCTIONS. There are no exceptions to this rule.
#
###########################################################################
###########################################################################
.include "../../devel/libtool/Makefile.common"
# XXX Tweaked for cross-compilation.
#PKGNAME= ${DISTNAME:S/-/-base-/}
PKGNAME= ${DISTNAME:S/^libtool-/cross-libtool-base-${MACHINE_ARCH}-/}
PKGREVISION= 5
COMMENT= Generic shared library support script (the script itself)
CONFLICTS+= libtool<=1.3.5nb11
TEST_TARGET= check
OVERRIDE_DIRDEPTH.install-sh= 1
# Always build libraries and executables that use the runtime linker.
# in addition, disable libtool locking, as the test is broken on AIX,
# and results in files being locked indefinitely.
LDFLAGS.AIX+= -Wl,-brtl
CONFIGURE_ARGS.AIX+= --disable-libtool-lock
# The MIPSpro compiler doesn't support -c with -o, but the locking
# workaround is itself broken. Disable it unconditionally.
CONFIGURE_ARGS.IRIX+= --disable-libtool-lock
CFLAGS.SunOS+= ${_COMPILER_ABI_FLAG.${ABI}}
# We are going to want libtool to find the same versions of the C, C++,
# and Fortran compilers.
#
USE_LANGUAGES= c c++
# XXX Added for cross-compilation. XXX Should be ${TARGET_ARCH}, but
# currently we have to fake-cross-compile libtool because it's broken
# upstream.
GNU_CONFIGURE_PREFIX= ${PREFIX}/cross-${MACHINE_ARCH}
CONFIGURE_ARGS+= --disable-ltdl-install
CONFIGURE_ARGS+= F77=no FC=no
USE_TOOLS+= echo
# XXX Added for cross-compilation.
FILESDIR= ../../devel/libtool-base/files
.PHONY: fix-libtool
fix-libtool:
cd ${WRKSRC}; for f in libtool; do \
${SED} -e "s,-L${BUILDLINK_DIR}/lib *,,g" \
-e "s,${BUILDLINK_DIR}/lib *,,g" \
$$f > $$f.new; \
if [ -x $$f ]; then ${CHMOD} +x $$f.new; fi; \
${MV} -f $$f.new $$f; \
done
post-build: fix-libtool
post-build:
@${SED} -e "s|@PREFIX@|"${PREFIX:Q}"|g" \
-e "s|@SH@|"${SH:Q}"|g" \
${FILESDIR}/shlibtool.in > ${WRKSRC}/shlibtool
post-install:
${INSTALL_SCRIPT} ${WRKSRC}/shlibtool ${DESTDIR}${PREFIX}/cross-${MACHINE_ARCH}/bin/shlibtool
BUILDLINK_DEPMETHOD.dlcompat= build
.include "../../mk/dlopen.buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
|