diff options
author | Marc Espie <espie@cvs.openbsd.org> | 2003-11-06 18:42:02 +0000 |
---|---|---|
committer | Marc Espie <espie@cvs.openbsd.org> | 2003-11-06 18:42:02 +0000 |
commit | 3b95b5380d82f74d1abad15b8deab882d4beb247 (patch) | |
tree | 7c4fcc8dd6d6d7854d6815d75bf29dd9ac6ef1bc /usr.sbin | |
parent | 602e8ed5e824ee0c42b2458c48b66a82d97eb319 (diff) |
set env PKG_PREFIX for compatibility with old tools.
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/pkg_add/pkg_add | 3 | ||||
-rw-r--r-- | usr.sbin/pkg_add/pkg_delete | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/pkg_add/pkg_add b/usr.sbin/pkg_add/pkg_add index 8eaa7fead8d..8dfffe0bad3 100644 --- a/usr.sbin/pkg_add/pkg_add +++ b/usr.sbin/pkg_add/pkg_add @@ -1,7 +1,7 @@ #! /usr/bin/perl # ex:ts=8 sw=4: -# $OpenBSD: pkg_add,v 1.9 2003/11/06 18:13:12 espie Exp $ +# $OpenBSD: pkg_add,v 1.10 2003/11/06 18:42:01 espie Exp $ # # Copyright (c) 2003 Marc Espie. # @@ -305,6 +305,7 @@ sub really_add($) my $plist = $handle->{plist}; my $dir = $handle->info(); my $pkgname = $plist->pkgname(); + $ENV{'PKG_PREFIX'} = $plist->prefix(); # check for collisions with existing stuff my $collisions = 0; for my $item (@{$plist->{items}}) { diff --git a/usr.sbin/pkg_add/pkg_delete b/usr.sbin/pkg_add/pkg_delete index 47546600625..cc26534467d 100644 --- a/usr.sbin/pkg_add/pkg_delete +++ b/usr.sbin/pkg_add/pkg_delete @@ -1,6 +1,6 @@ #!/usr/bin/perl # ex:ts=8 sw=4: -# $OpenBSD: pkg_delete,v 1.10 2003/11/06 17:49:31 espie Exp $ +# $OpenBSD: pkg_delete,v 1.11 2003/11/06 18:42:01 espie Exp $ # # Copyright (c) 2003 Marc Espie. # @@ -272,6 +272,7 @@ sub delete_package die "Package $pkgname real name does not match"; } + $ENV{'PKG_PREFIX'} = $plist->prefix(); if ($plist->has(REQUIRE)) { $plist->get(REQUIRE)->delete($state); } |