From 82c36963aebbc9857585762c82c7a5d111420c7e Mon Sep 17 00:00:00 2001 From: Marc Espie Date: Sat, 9 Jun 2007 11:16:55 +0000 Subject: rework `special' package names a bit. - do a test to create partial-foo-1.0.1 instead of partial-partial-foo-1.0 when removing partial-foo fails. - have .libs name generation, e.g., .libs-foo, then .libs1-foo, then .libs2-foo instead of .libs-.libs-foo.... extend the pkgspec pattern slightly, so that all these are more or less equivalent for dependencies and conflicts. With this, we can do practically any scenario of shared libs updates and downgrades. --- usr.sbin/pkg_add/OpenBSD/Replace.pm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'usr.sbin/pkg_add/OpenBSD/Replace.pm') diff --git a/usr.sbin/pkg_add/OpenBSD/Replace.pm b/usr.sbin/pkg_add/OpenBSD/Replace.pm index 5e85ec86998..b64aa60b27f 100644 --- a/usr.sbin/pkg_add/OpenBSD/Replace.pm +++ b/usr.sbin/pkg_add/OpenBSD/Replace.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: Replace.pm,v 1.38 2007/06/09 10:30:53 espie Exp $ +# $OpenBSD: Replace.pm,v 1.39 2007/06/09 11:16:54 espie Exp $ # # Copyright (c) 2004-2006 Marc Espie # @@ -376,7 +376,9 @@ sub split_libs (my $splitted, $plist) = split_some_libs($plist, $to_split); - $splitted->set_pkgname(".libs-".$plist->pkgname); + require OpenBSD::PackageInfo; + + $splitted->set_pkgname(OpenBSD::PackageInfo::libs_package($plist->pkgname)); if (defined $plist->{'no-default-conflict'}) { # we conflict with the package we just removed... -- cgit v1.2.3