summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2001-06-23 19:38:55 +0000
committerjlam <jlam@pkgsrc.org>2001-06-23 19:38:55 +0000
commit0e9e7bbb8686e6d49194ba528ced77b8ed60afc4 (patch)
treebe3e86fec58a8ef73fbe15d77097f7e6aa1fc9f4 /mk
parent01cd2720880b647312b92729c1c758be6ed437c4 (diff)
downloadpkgsrc-0e9e7bbb8686e6d49194ba528ced77b8ed60afc4.tar.gz
Factor out the sed expression used to fix libtool archives into a variable,
BUILDLINK_FIX_LIBTOOL_SED, that may be appended to.
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.buildlink.mk9
1 files changed, 6 insertions, 3 deletions
diff --git a/mk/bsd.buildlink.mk b/mk/bsd.buildlink.mk
index eb1ef2cedeb..845fa0a12a8 100644
--- a/mk/bsd.buildlink.mk
+++ b/mk/bsd.buildlink.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.buildlink.mk,v 1.13 2001/06/21 03:45:03 jlam Exp $
+# $NetBSD: bsd.buildlink.mk,v 1.14 2001/06/23 19:38:55 jlam Exp $
#
# This Makefile fragment is included by package buildlink.mk files. This
# file does the following things:
@@ -145,6 +145,8 @@ _BUILDLINK_CONFIG_WRAPPER_USE: .USE
.if defined(USE_LIBTOOL)
post-build: buildlink-fix-libtool-archives
+BUILDLINK_FIX_LIBTOOL_SED+= -e "s|-L${BUILDLINK_DIR}/|-L${LOCALBASE}/|g"
+
# Note: This target _MUST_ know something about libtool internals to correctly
# fix the references to ${BUILDLINK_DIR} into ${LOCALBASE}.
#
@@ -152,11 +154,12 @@ buildlink-fix-libtool-archives:
${_PKG_SILENT}${_PKG_DEBUG} \
cookie=${BUILDLINK_DIR}/.buildlink_fix_libtool_archives_done; \
if [ ! -f $${cookie} ]; then \
- ${ECHO_MSG} "Fixing directory references in libtool archives."; \
+ ${ECHO_MSG} "Fixing directory references in libtool archives:"; \
lai_files=`${FIND} ${WRKSRC} -name "*.lai"`; \
for file in $${lai_files}; do \
+ ${ECHO_MSG} " $${file}"; \
${MV} -f $${file} $${file}.fixme; \
- ${SED} -e "s|-L${BUILDLINK_DIR}|-L${LOCALBASE}|g" \
+ ${SED} ${BUILDLINK_FIX_LIBTOOL_SED} \
$${file}.fixme > $${file}; \
${RM} -f $${file}.fixme; \
done; \