summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2007-05-02 15:17:37 +0000
committerMarc Espie <espie@cvs.openbsd.org>2007-05-02 15:17:37 +0000
commitd1d1499aa7a2061b47894e26206e908549fe3390 (patch)
treedd34fb6409c0cbd93ee29c8df7384edf934600b8
parent70e9f2aea1be8962756db82630ca5da40703bb8e (diff)
replace pkgbase with less confusing name localbase
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Delete.pm4
-rw-r--r--usr.sbin/pkg_add/OpenBSD/Dependencies.pm10
-rw-r--r--usr.sbin/pkg_add/OpenBSD/PackingList.pm6
-rw-r--r--usr.sbin/pkg_add/pkg_add8
-rw-r--r--usr.sbin/pkg_add/pod/OpenBSD::PackingList.pod6
5 files changed, 17 insertions, 17 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Delete.pm b/usr.sbin/pkg_add/OpenBSD/Delete.pm
index 4940439bf39..3f57924582a 100644
--- a/usr.sbin/pkg_add/OpenBSD/Delete.pm
+++ b/usr.sbin/pkg_add/OpenBSD/Delete.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: Delete.pm,v 1.37 2007/05/02 15:05:29 espie Exp $
+# $OpenBSD: Delete.pm,v 1.38 2007/05/02 15:17:36 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
@@ -161,7 +161,7 @@ sub delete_plist
$state->{pkgname} = $pkgname;
my $dir = installed_info($pkgname);
$state->{dir} = $dir;
- $ENV{'PKG_PREFIX'} = $plist->pkgbase;
+ $ENV{'PKG_PREFIX'} = $plist->localbase;
if ($plist->has(REQUIRE)) {
$plist->get(REQUIRE)->delete($state);
}
diff --git a/usr.sbin/pkg_add/OpenBSD/Dependencies.pm b/usr.sbin/pkg_add/OpenBSD/Dependencies.pm
index 89917c643bc..854316945cc 100644
--- a/usr.sbin/pkg_add/OpenBSD/Dependencies.pm
+++ b/usr.sbin/pkg_add/OpenBSD/Dependencies.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: Dependencies.pm,v 1.11 2007/05/02 15:05:29 espie Exp $
+# $OpenBSD: Dependencies.pm,v 1.12 2007/05/02 15:17:36 espie Exp $
#
# Copyright (c) 2005-2007 Marc Espie <espie@openbsd.org>
#
@@ -153,7 +153,7 @@ sub lookup_library
{
my ($state, $lib, $plist, $dependencies, $harder, $done) = @_;
- my $r = check_lib_spec($plist->pkgbase(), $lib, $dependencies);
+ my $r = check_lib_spec($plist->localbase, $lib, $dependencies);
if ($r) {
print "found libspec $lib in $r\n" if $state->{very_verbose};
return 1;
@@ -171,7 +171,7 @@ sub lookup_library
}
}
for my $dep (@{$plist->{depends}}) {
- $r = find_old_lib($state, $plist->pkgbase, $dep->{pattern}, $lib, $dependencies);
+ $r = find_old_lib($state, $plist->localbase, $dep->{pattern}, $lib, $dependencies);
if ($r) {
print "found libspec $lib in old package $r\n" if $state->{verbose};
return 1;
@@ -190,7 +190,7 @@ sub lookup_library
}
next if $dependencies->{$dep};
OpenBSD::SharedLibs::add_package_libs($dep);
- if (check_lib_spec($plist->pkgbase, $lib, {$dep => 1})) {
+ if (check_lib_spec($plist->localbase, $lib, {$dep => 1})) {
print "found libspec $lib in dependent package $dep\n" if $state->{verbose};
$dependencies->{$dep} = 1;
return 1;
@@ -210,7 +210,7 @@ sub lookup_library
push(@todo, $dep2) unless $done->{$dep2};
}
OpenBSD::SharedLibs::add_bogus_package_libs($dep);
- if (check_lib_spec($plist->pkgbase(), $lib, {$dep => 1})) {
+ if (check_lib_spec($plist->localbase, $lib, {$dep => 1})) {
print "found libspec $lib in dependent package $dep (unmarked library)\n" if $state->{verbose};
$dependencies->{$dep} = 1;
return 1;
diff --git a/usr.sbin/pkg_add/OpenBSD/PackingList.pm b/usr.sbin/pkg_add/OpenBSD/PackingList.pm
index 0458f6e0b0c..ce56c03edd1 100644
--- a/usr.sbin/pkg_add/OpenBSD/PackingList.pm
+++ b/usr.sbin/pkg_add/OpenBSD/PackingList.pm
@@ -1,5 +1,5 @@
# ex:ts=8 sw=4:
-# $OpenBSD: PackingList.pm,v 1.61 2007/05/02 15:13:05 espie Exp $
+# $OpenBSD: PackingList.pm,v 1.62 2007/05/02 15:17:36 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
@@ -294,13 +294,13 @@ sub get
return $plist->{$name};
}
-sub pkgname($)
+sub pkgname
{
my $self = shift;
return $self->{name}->{name};
}
-sub pkgbase($)
+sub localbase
{
my $self = shift;
diff --git a/usr.sbin/pkg_add/pkg_add b/usr.sbin/pkg_add/pkg_add
index 216e4301f80..3fc25461cd9 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.229 2007/05/02 13:59:19 espie Exp $
+# $OpenBSD: pkg_add,v 1.230 2007/05/02 15:17:36 espie Exp $
#
# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
#
@@ -164,8 +164,8 @@ sub pre_add($$)
$errors++;
return;
}
- if ($plist->pkgbase ne $state->{localbase}) {
- print "Localbase mismatch: package has: ", $plist->pkgbase, " , user wants: ", $state->{localbase}, "\n";
+ if ($plist->localbase ne $state->{localbase}) {
+ print "Localbase mismatch: package has: ", $plist->localbase, " , user wants: ", $state->{localbase}, "\n";
$errors++;
return;
}
@@ -286,7 +286,7 @@ sub really_add($$)
Fatal "Archive in $pkgname broken";
}
- $ENV{'PKG_PREFIX'} = $plist->pkgbase;
+ $ENV{'PKG_PREFIX'} = $plist->localbase;
my $interrupted;
my $handler = sub {
diff --git a/usr.sbin/pkg_add/pod/OpenBSD::PackingList.pod b/usr.sbin/pkg_add/pod/OpenBSD::PackingList.pod
index 5c5794bf796..e3223d7bb80 100644
--- a/usr.sbin/pkg_add/pod/OpenBSD::PackingList.pod
+++ b/usr.sbin/pkg_add/pod/OpenBSD::PackingList.pod
@@ -1,4 +1,4 @@
-$OpenBSD: OpenBSD::PackingList.pod,v 1.6 2007/04/29 10:52:15 espie Exp $
+$OpenBSD: OpenBSD::PackingList.pod,v 1.7 2007/05/02 15:17:36 espie Exp $
=head1 NAME
@@ -29,7 +29,7 @@ OpenBSD::PackingList - C<pkg_add(1)> packing-list manipulations
$b = $p2->has($name);
$b = $p2->get($name);
# frequent accesses
- print $p3->pkgname(), $p3->pkgbase(), "\n";
+ print $p3->pkgname, $p3->localbase, "\n";
# processing packing-lists
$p4->visit('method', @args);
@@ -38,7 +38,7 @@ OpenBSD::PackingList - C<pkg_add(1)> packing-list manipulations
$p4->method(@args);
# signatures
- if ($p3->signature() eq $p4->signature()) {
+ if ($p3->signature eq $p4->signature) {
}
=head1 DESCRIPTION