From 0c4917e91868550095ecd1d4b0919a939131dedb Mon Sep 17 00:00:00 2001 From: dmcmahill Date: Wed, 2 May 2001 13:51:43 +0000 Subject: do some extra checks. In particular, don't try to pkg_add a package if it doesn't exist (doh!). --- mk/bulk/bsd.bulk-pkg.mk | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'mk') diff --git a/mk/bulk/bsd.bulk-pkg.mk b/mk/bulk/bsd.bulk-pkg.mk index 6614272cf6e..88ae8bd085e 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.23 2001/03/31 00:03:03 dmcmahill Exp $ +# $NetBSD: bsd.bulk-pkg.mk,v 1.24 2001/05/02 13:51:43 dmcmahill Exp $ # # Copyright (c) 1999, 2000 Hubert Feyrer @@ -236,8 +236,12 @@ bulk-package: pkgname=`${GREP} "^$$pkgdir " ${INDEXFILE} | ${AWK} '{print $$2}'` ; \ pkgfile=${PACKAGES}/All/$${pkgname}.tgz ;\ if ! `${PKG_INFO} -qe $$pkgname` ; then \ - ${ECHO_MSG} "BULK> " ${PKG_ADD} $$pkgfile ; \ - ${DO} ${PKG_ADD} $$pkgfile ; \ + if [ -f $$pkgfile ]; then \ + ${ECHO_MSG} "BULK> ${PKG_ADD} $$pkgfile"; \ + ${DO} ${PKG_ADD} $$pkgfile ; \ + else \ + ${ECHO_MSG} "BULK> warning: $$pkgfile does not exist. It will be rebuilt." ;\ + fi ;\ else \ ${ECHO_MSG} "BULK> Required package $$pkgname ($$pkgdir) is already installed" ; \ fi ;\ -- cgit v1.2.3