diff options
Diffstat (limited to 'perl-install/crypto.pm')
-rw-r--r-- | perl-install/crypto.pm | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/perl-install/crypto.pm b/perl-install/crypto.pm index 3e362fdf8..23b4dc93f 100644 --- a/perl-install/crypto.pm +++ b/perl-install/crypto.pm @@ -146,11 +146,13 @@ sub bestMirror { $possible[rand @possible]; } -#- hack to retrieve Mandrivaalinux version... +#- hack to retrieve Mandriva Linux version... XXX figure out something more robust sub version() { require pkgs; - my $pkg = pkgs::packageByName($::o->{packages}, 'mandrakelinux-release'); - $pkg && $pkg->version || '9.1'; #- safe but dangerous ;-) + my $pkg = pkgs::packageByName($::o->{packages}, 'mandriva-release'); + my $v = $pkg && $pkg->version || '10.2'; #- safe but dangerous ;-) + $v eq '2006.0' and $v = '10.2'; + $v; } sub dir { $mirrors{$_[0]}[1] } |