From 90bcde26b209336d1022b34ab02125c335b55208 Mon Sep 17 00:00:00 2001 From: jlam Date: Tue, 27 Jan 2004 12:19:03 +0000 Subject: Abstract out the filter commmand used to list headers and libraries in the package +CONTENTS file into a variable BUILDLINK_CONTENTS_FILTER.. --- mk/buildlink3/bsd.buildlink3.mk | 28 +++++++++++++++++----------- 1 file changed, 17 insertions(+), 11 deletions(-) (limited to 'mk') 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. # shell pipeline that outputs to stdout a list of files relative # to ${BUILDLINK_PREFIX.}. The resulting files are to be -# symlinked into ${BUILDLINK_DIR}. By default for overwrite -# packages, BUILDLINK_FILES_CMD. 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 and filters it through +# ${BUILDLINK_CONTENTS_FILTER.}. +# +# BUILDLINK_CONTENTS_FILTER. +# filter command that filters +CONTENTS input into a list of files +# relative to ${BUILDLINK_PREFIX.} on stdout. By default for +# overwrite packages, BUILDLINK_CONTENTS_FILTER. 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. # 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. combines BUILDLINK_FILES_CMD. and # BUILDLINK_FILES. into one command that outputs all of the files -- cgit v1.2.3