summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authortv <tv>2005-01-12 22:51:54 +0000
committertv <tv>2005-01-12 22:51:54 +0000
commit04d1f5dbf0703744a2a36ca96bbdba1bdcb5dfa5 (patch)
tree217f20c2987b0fcc2802948ef8bd8e20cfbd2dad /mk
parentca7c7f617b1c5220c6fa1278f4405a99fafa1cdb (diff)
downloadpkgsrc-04d1f5dbf0703744a2a36ca96bbdba1bdcb5dfa5.tar.gz
Fix checking of up to date binary packages. The problem with DEPENDS
containing constructs of the form {perl>=5.8.3nb1,perl-thread>=5.8.3nb1} is that a Bourne shell "for" interprets this as two separate items in the list, nuking the {}s. The above will never succeed and thus always cause Perl-dependent packages to be rebuilt unconditionally. Just adding more \s isn't enough -- the parsing of the depends list has to be moved out of the "for" clause. So, echo them one per line and use "read" to pull them in without allowing the shell to peek at those characters.
Diffstat (limited to 'mk')
-rw-r--r--mk/bulk/bsd.bulk-pkg.mk6
1 files changed, 3 insertions, 3 deletions
diff --git a/mk/bulk/bsd.bulk-pkg.mk b/mk/bulk/bsd.bulk-pkg.mk
index 65d5f1fedb0..7c68f88e07b 100644
--- a/mk/bulk/bsd.bulk-pkg.mk
+++ b/mk/bulk/bsd.bulk-pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.bulk-pkg.mk,v 1.67 2005/01/11 18:44:10 tv Exp $
+# $NetBSD: bsd.bulk-pkg.mk,v 1.68 2005/01/12 22:51:54 tv Exp $
#
# Copyright (c) 1999, 2000 Hubert Feyrer <hubertf@NetBSD.org>
@@ -207,8 +207,8 @@ bulk-check-uptodate:
fi ; \
if [ "$$uptodate" = "1" ]; then \
${SHCOMMENT} "Check required binary packages" ; \
- deps=${DEPENDS:C/:.*//:Q} ; \
- for dep in $$deps ; do \
+ (${DEPENDS:C/:.*$//:@d@${ECHO} ${d:Q};@} ${TRUE}) | \
+ while read dep; do \
${SHCOMMENT} "check against the binary pkg that pkg_add would pick, too:" ; \
${SHCOMMENT} "(Only one should be returned here, really...)" ; \
pkg=`${PKG_ADMIN} lsbest "${PACKAGES}/All/$$dep"` ; \