diff options
author | agc <agc> | 2003-04-29 20:31:52 +0000 |
---|---|---|
committer | agc <agc> | 2003-04-29 20:31:52 +0000 |
commit | a6560c73fe180e0503c0afc41cbe9e500f681b7e (patch) | |
tree | 821fea685a042d80cc3931ad27fb2dfb059429c4 /mk | |
parent | 2c4dd2af8263a1ae32e78e0f7a531f84ea125ebc (diff) | |
download | pkgsrc-a6560c73fe180e0503c0afc41cbe9e500f681b7e.tar.gz |
Speed-ups for the check-vulnerable target, from Jeremy Reed in PR 21393.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/bsd.pkg.mk | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk index 2bfff89be3f..72ca23ea6b9 100644 --- a/mk/bsd.pkg.mk +++ b/mk/bsd.pkg.mk @@ -1,4 +1,4 @@ -# $NetBSD: bsd.pkg.mk,v 1.1174 2003/04/29 20:27:50 agc Exp $ +# $NetBSD: bsd.pkg.mk,v 1.1175 2003/04/29 20:31:52 agc Exp $ # # This file is in the public domain. # @@ -1409,7 +1409,10 @@ batch-check-distfiles: check-vulnerable: @if [ -f ${PKGVULNDIR}/vulnerabilities ]; then \ ${SETENV} PKGNAME="${PKGNAME}" \ - ${AWK} '/#.*/ { next } \ + PKGBASE="${PKGBASE}" \ + ${AWK} '/^$$/ { next } \ + /^#.*/ { next } \ + $$1 !~ ENVIRON["PKGBASE"]) { 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}/vulnerabilities || ${FALSE}; \ fi |