diff options
author | minskim <minskim@pkgsrc.org> | 2004-08-04 06:22:39 +0000 |
---|---|---|
committer | minskim <minskim@pkgsrc.org> | 2004-08-04 06:22:39 +0000 |
commit | 7f8cb7a6648fde4301a85b62bb21d8fbf0081658 (patch) | |
tree | c7d984f159440991d033af9725332dcfd9de2cd7 /mk | |
parent | 2cae6d078e10201357532361595b24cd20fc21ac (diff) | |
download | pkgsrc-7f8cb7a6648fde4301a85b62bb21d8fbf0081658.tar.gz |
Do not run xargs if its input is an empty string; xargs in Interix
executes the utility even in such a case. Based on the patch provided
by Hiramatsu Yoshifumi in PR pkg/25777.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/bsd.pkg.mk | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index 37823d682ed..d0fe24bd9b6 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.1482 2004/08/04 02:56:01 jschauma Exp $ +# $NetBSD: bsd.pkg.mk,v 1.1483 2004/08/04 06:22:39 minskim Exp $ # # This file is in the public domain. # @@ -4342,14 +4342,19 @@ print-pkg-size-this: # dependencies are all installed. .PHONY: print-pkg-size-depends print-pkg-size-depends: - @${MAKE} ${MAKEFLAGS} run-depends-list \ - | ${XARGS} -n 1 ${SETENV} ${PKG_BEST_EXISTS} \ - | ${SORT} -u \ - | ${XARGS} -n 256 ${SETENV} ${PKG_INFO} -qs \ - | ${AWK} -- 'BEGIN { print("0 "); } \ - /^[0-9]+$$/ { print($$1, " + "); } \ - END { print("p"); }' \ - | ${DC} + @pkglist=`${MAKE} ${MAKEFLAGS} run-depends-list`; \ + if [ "X$${pkglist}" != "X" ]; then \ + ${ECHO} $${pkglist} \ + | ${XARGS} -n 1 ${SETENV} ${PKG_BEST_EXISTS} \ + | ${SORT} -u \ + | ${XARGS} -n 256 ${SETENV} ${PKG_INFO} -qs \ + | ${AWK} -- 'BEGIN { print("0 "); } \ + /^[0-9]+$$/ { print($$1, " + "); } \ + END { print("p"); }' \ + | ${DC}; \ + else \ + ${ECHO} "0"; \ + fi ### |