summaryrefslogtreecommitdiff
path: root/mk/bsd.pkg.mk
diff options
context:
space:
mode:
authoragc <agc@pkgsrc.org>2005-03-31 21:02:28 +0000
committeragc <agc@pkgsrc.org>2005-03-31 21:02:28 +0000
commit974f1af6e8d1f9515df8053676046b474f8357b9 (patch)
treebaba9ee3c750bcbe9caf28be0f7ad13ff1c20ed9 /mk/bsd.pkg.mk
parentab438d2110181bbcfe49257c5d50707690d135cd (diff)
downloadpkgsrc-974f1af6e8d1f9515df8053676046b474f8357b9.tar.gz
Fix for PR 28230 (bsd.pkg.mk ignores /etc/audit-packages.conf) by
sourcing any config file, if it's defined. With thanks to Julio M. Merino Vidal for the first pass at a fix, and for keeping me honest and up-to-date with variable checks in portable shell constructs.
Diffstat (limited to 'mk/bsd.pkg.mk')
-rw-r--r--mk/bsd.pkg.mk9
1 files changed, 7 insertions, 2 deletions
diff --git a/mk/bsd.pkg.mk b/mk/bsd.pkg.mk
index a3738f56f9a..1decf07fab5 100644
--- a/mk/bsd.pkg.mk
+++ b/mk/bsd.pkg.mk
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.pkg.mk,v 1.1605 2005/03/29 08:17:42 garbled Exp $
+# $NetBSD: bsd.pkg.mk,v 1.1606 2005/03/31 21:02:28 agc Exp $
#
# This file is in the public domain.
#
@@ -1405,7 +1405,12 @@ batch-check-distfiles:
# Please do not modify the leading "@" here
.PHONY: check-vulnerable
check-vulnerable:
- @if [ -f ${PKGVULNDIR}/pkg-vulnerabilities ]; then \
+ @if [ ! -z "${PKG_SYSCONFDIR.audit-packages}" -a -f ${PKG_SYSCONFDIR.audit-packages}/audit-packages.conf ]; then \
+ . ${PKG_SYSCONFDIR.audit-packages}/audit-packages.conf; \
+ elif [ ! -z "${PKG_SYSCONFDIR}" -a -f ${PKG_SYSCONFDIR}/audit-packages.conf ]; then \
+ . ${PKG_SYSCONFDIR}/audit-packages.conf; \
+ fi; \
+ if [ -f $${PKGVULNDIR}/pkg-vulnerabilities ]; then \
${SETENV} PKGNAME="${PKGNAME}" \
PKGBASE="${PKGBASE}" \
${AWK} '/^$$/ { next } \