Subject: Re: pkg/9888: "make print-pkg-size" is broken on some package.
To: None <gnats-bugs@gnats.netbsd.org>
From: Takahiro Kambe <taca@sky.yamashina.kyoto.jp>
List: netbsd-bugs
Date: 04/15/2000 12:37:35
Oh, I've attached slightly old diff.
--
Takahiro Kambe <taca@sky.yamashina.kyoto.jp>
--- mk/bsd.pkg.mk.orig Fri Apr 14 14:47:12 2000
+++ mk/bsd.pkg.mk Sat Apr 15 12:35:39 2000
@@ -2562,9 +2562,10 @@
print-pkg-size:
${_PKG_SILENT}${_PKG_DEBUG}( \
${SHCOMMENT} "This pkg's files" ; \
- ${SED} -n \
- -e 's,^[^@],${PREFIX}/&,' \
- -e '/^\//p' \
+ ${AWK} 'BEGIN { base = "${PREFIX}/" } \
+ /^@cwd/ { base = $$2 "/" } \
+ /^@ignore/ { next } \
+ NF == 1 { print base $$1 }' \
<${PLIST} ; \
${SHCOMMENT} "Any depending pkgs' files" ; \
if [ "${SIZEDEPENDS}" != "" ]; then \