summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorjlam <jlam>2004-01-27 12:19:03 +0000
committerjlam <jlam>2004-01-27 12:19:03 +0000
commit90bcde26b209336d1022b34ab02125c335b55208 (patch)
treebb4e95444a82fa9ac2e2ceb830bab295ba092288 /mk
parent1f3104c57c0dea76868fc1207e91bda65a920796 (diff)
downloadpkgsrc-90bcde26b209336d1022b34ab02125c335b55208.tar.gz
Abstract out the filter commmand used to list headers and libraries in
the package +CONTENTS file into a variable BUILDLINK_CONTENTS_FILTER.<pkg>.
Diffstat (limited to 'mk')
-rw-r--r--mk/buildlink3/bsd.buildlink3.mk28
1 files changed, 17 insertions, 11 deletions
diff --git a/mk/buildlink3/bsd.buildlink3.mk b/mk/buildlink3/bsd.buildlink3.mk
index 7dfffc0641c..2e794b6aa71 100644
--- a/mk/buildlink3/bsd.buildlink3.mk
+++ b/mk/buildlink3/bsd.buildlink3.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.buildlink3.mk,v 1.63 2004/01/27 08:42:13 jlam Exp $
+# $NetBSD: bsd.buildlink3.mk,v 1.64 2004/01/27 12:19:03 jlam Exp $
#
# An example package buildlink3.mk file:
#
@@ -429,11 +429,17 @@ do-buildlink: buildlink-wrappers buildlink-${_BLNK_OPSYS}-wrappers
# BUILDLINK_FILES_CMD.<pkg>
# shell pipeline that outputs to stdout a list of files relative
# to ${BUILDLINK_PREFIX.<pkg>}. The resulting files are to be
-# symlinked into ${BUILDLINK_DIR}. By default for overwrite
-# packages, BUILDLINK_FILES_CMD.<pkg> outputs the contents of the
-# include and lib directories in the package +CONTENTS, and for
-# pkgviews packages, it outputs any libtool archives in lib
-# directories.
+# symlinked into ${BUILDLINK_DIR}. By default, this takes the
+# +CONTENTS of a <pkg> and filters it through
+# ${BUILDLINK_CONTENTS_FILTER.<pkg>}.
+#
+# BUILDLINK_CONTENTS_FILTER.<pkg>
+# filter command that filters +CONTENTS input into a list of files
+# relative to ${BUILDLINK_PREFIX.<pkg>} on stdout. By default for
+# overwrite packages, BUILDLINK_CONTENTS_FILTER.<pkg> outputs the
+# contents of the include and lib directories in the package
+# +CONTENTS, and for pkgviews packages, it outputs any libtool
+# archives in lib directories.
#
# BUILDLINK_TRANSFORM.<pkg>
# sed arguments used to transform the name of the source filename
@@ -464,16 +470,16 @@ buildlink-${_pkg_}-cookie:
. if (${PKG_INSTALLATION_TYPE} == "pkgviews") && \
!empty(BUILDLINK_IS_DEPOT.${_pkg_}:M[yY][eE][sS])
-BUILDLINK_FILES_CMD.${_pkg_}?= \
- ${_BLNK_PKG_INFO.${_pkg_}} -f ${BUILDLINK_PKGNAME.${_pkg_}} | \
- ${SED} -n '/File:/s/^[ ]*File:[ ]*//p' | \
+BUILDLINK_CONTENTS_FILTER.${_pkg_}?= \
${GREP} 'lib.*/lib[^/]*\.la$$'
. else
+BUILDLINK_CONTENTS_FILTER.${_pkg_}?= \
+ ${EGREP} '(include.*/|lib.*/lib[^/]*$$)'
+. endif
BUILDLINK_FILES_CMD.${_pkg_}?= \
${_BLNK_PKG_INFO.${_pkg_}} -f ${BUILDLINK_PKGNAME.${_pkg_}} | \
${SED} -n '/File:/s/^[ ]*File:[ ]*//p' | \
- ${EGREP} '(include.*/|lib.*/lib[^/]*$$)'
-. endif
+ ${BUILDLINK_CONTENTS_FILTER.${_pkg_}}
# _BLNK_FILES_CMD.<pkg> combines BUILDLINK_FILES_CMD.<pkg> and
# BUILDLINK_FILES.<pkg> into one command that outputs all of the files