summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authoragc <agc@pkgsrc.org>2005-03-13 09:30:31 +0000
committeragc <agc@pkgsrc.org>2005-03-13 09:30:31 +0000
commit113eb1558fd6d7bf0a6e13dc52e40f3e6fe013f7 (patch)
treea77b52b54d1adc32e12ff54c4beb8443b45727df /mk
parent9fb1d80396780d7afac9944687d25dd4e2799149 (diff)
downloadpkgsrc-113eb1558fd6d7bf0a6e13dc52e40f3e6fe013f7.tar.gz
Put back the speed-up in the vulnerability checking when building a package,
but disable this if the package name in the pkg-vulnerabilities file contains a meta-character. This speeds up the check-vulnerable target from: [9:28:06] agc@sys3 ...pkgsrc/misc/libutf 11 > time make check-vulnerable 1.821u 1.988s 0:02.57 147.8% 0+0k 0+0io 0pf+0w [9:28:17] agc@sys3 ...pkgsrc/misc/libutf 12 > to [9:28:27] agc@sys3 ...pkgsrc/misc/libutf 13 > time make check-vulnerable 0.273u 0.233s 0:00.33 151.5% 0+0k 0+0io 0pf+0w [9:28:30] agc@sys3 ...pkgsrc/misc/libutf 14 > (with caches filled, on a fairly fast machine - P4 2.8 GHz, 2GB RAM).
Diffstat (limited to 'mk')
-rw-r--r--mk/bsd.pkg.mk3
1 files changed, 2 insertions, 1 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index fa166f2f731..0cb466d9c5f 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.1597 2005/03/02 11:11:36 agc Exp $
+# $NetBSD: bsd.pkg.mk,v 1.1598 2005/03/13 09:30:31 agc Exp $
#
# This file is in the public domain.
#
@@ -1393,6 +1393,7 @@ check-vulnerable:
PKGBASE="${PKGBASE}" \
${AWK} '/^$$/ { next } \
/^#.*/ { next } \
+ $$1 !~ ENVIRON["PKGBASE"] && $$1 !~ /\{/ { next } \
{ s = sprintf("${PKG_ADMIN} pmatch \"%s\" %s && ${ECHO} \"*** WARNING - %s vulnerability in %s - see %s for more information ***\"", $$1, ENVIRON["PKGNAME"], $$2, ENVIRON["PKGNAME"], $$3); system(s); }' < ${PKGVULNDIR}/pkg-vulnerabilities || ${FALSE}; \
fi