diff options
author | abs <abs@pkgsrc.org> | 2001-08-08 13:41:43 +0000 |
---|---|---|
committer | abs <abs@pkgsrc.org> | 2001-08-08 13:41:43 +0000 |
commit | 8b66e2d83fa2da36ba42a112a4f66454fa945778 (patch) | |
tree | b4449f5430f7e355ae933aefc086a99f2236f4a9 | |
parent | 38eaabc156bb188f43c401788c46ade9e1d9df8d (diff) | |
download | pkgsrc-8b66e2d83fa2da36ba42a112a4f66454fa945778.tar.gz |
Update pkgchk to 1.08:
Check during install if packages have already been installed.
Avoids reinstalling a package if it had already been installed as
a depends on a previous package.
-rw-r--r-- | pkgtools/pkgchk/Makefile | 4 | ||||
-rwxr-xr-x | pkgtools/pkgchk/files/pkgchk.sh | 7 |
2 files changed, 6 insertions, 5 deletions
diff --git a/pkgtools/pkgchk/Makefile b/pkgtools/pkgchk/Makefile index efbf27d09ec..88c5c1cd297 100644 --- a/pkgtools/pkgchk/Makefile +++ b/pkgtools/pkgchk/Makefile @@ -1,6 +1,6 @@ -# $NetBSD: Makefile,v 1.8 2001/07/31 17:32:06 tron Exp $ +# $NetBSD: Makefile,v 1.9 2001/08/08 13:41:43 abs Exp $ -DISTNAME= pkgchk-1.07 +DISTNAME= pkgchk-1.08 CATEGORIES= pkgtools MASTER_SITES= # empty DISTFILES= # empty diff --git a/pkgtools/pkgchk/files/pkgchk.sh b/pkgtools/pkgchk/files/pkgchk.sh index b5fc36707d9..faa6362f212 100755 --- a/pkgtools/pkgchk/files/pkgchk.sh +++ b/pkgtools/pkgchk/files/pkgchk.sh @@ -1,9 +1,8 @@ #!/bin/sh -e # -# $Id: pkgchk.sh,v 1.8 2001/07/31 17:32:07 tron Exp $ +# $Id: pkgchk.sh,v 1.9 2001/08/08 13:41:43 abs Exp $ # # TODO: Handle and as well as or tags (eg: i386+x11) -# TODO: Order updates based on DEPENDENCIES. # TODO: Handle updates with dependencies via binary packages extract_variables() @@ -45,7 +44,9 @@ pkg_install() PKGNAME=$1 PKGDIR=$2 INSTALL=$3 - if [ -n "$opt_b" -a -f $PACKAGES/All/$PKGNAME.tgz ] ; then + if [ -d /var/db/pkg/$PKGNAME ];then + echo "$PKGNAME installed in previous stage" + elif [ -n "$opt_b" -a -f $PACKAGES/All/$PKGNAME.tgz ] ; then if [ $INSTALL = U ];then PKG=`echo $PKGNAME | sed 's/-[0-9].*//'` echo "pkg_delete $PKG" |