summaryrefslogtreecommitdiffstats
path: root/urpmi.addmedia
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2000-03-26 17:24:04 +0000
committerPascal Rigaux <pixel@mandriva.com>2000-03-26 17:24:04 +0000
commita982d562a19e1bf9d421cc64127635e403dd3f39 (patch)
tree0d50576692fb37646fb5c4fd837e55eab88f7f7f /urpmi.addmedia
parente922549802d625842f87ce2e1857685074f6b344 (diff)
downloadurpmi-a982d562a19e1bf9d421cc64127635e403dd3f39.tar
urpmi-a982d562a19e1bf9d421cc64127635e403dd3f39.tar.gz
urpmi-a982d562a19e1bf9d421cc64127635e403dd3f39.tar.bz2
urpmi-a982d562a19e1bf9d421cc64127635e403dd3f39.tar.xz
urpmi-a982d562a19e1bf9d421cc64127635e403dd3f39.zip
no_comment
Diffstat (limited to 'urpmi.addmedia')
-rwxr-xr-xurpmi.addmedia8
1 files changed, 7 insertions, 1 deletions
diff --git a/urpmi.addmedia b/urpmi.addmedia
index 468e675d..be89cdf1 100755
--- a/urpmi.addmedia
+++ b/urpmi.addmedia
@@ -86,7 +86,13 @@ my $RPMLIST = "$DIR/list.$name";
!-e $HDLIST || unlink $HDLIST or die "can't remove $HDLIST";
if (my ($prefix, $dir) = $url =~ m,^(removable_.*?|file):/(.*),) {
- if (-e (my $f = "$dir/Mandrake/base/hdlist.cz2")) {
+ my $f;
+ if ($dir =~ /RPMS(.*)$/) {
+ $f = "$dir/Mandrake/base/hdlist$1.cz2";
+ $f = "$dir/../base/hdlist$1.cz2" unless -e $f;
+ $f = "$dir/../hdlist$1.cz2" unless -e $f;
+ }
+ if (-e $f) {
system("cp -f $f $HDLIST");
} else {
system("genhdlist_cz2 -o $HDLIST $dir");