summaryrefslogtreecommitdiffstats
path: root/perl-install/bootloader.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2007-08-31 10:19:11 +0000
committerPascal Rigaux <pixel@mandriva.com>2007-08-31 10:19:11 +0000
commit149ca71e19a3b0b019ab13d6366f201ad5bdd7d7 (patch)
treeaaca7079ad5627afbd460f191f17ad54e22787dc /perl-install/bootloader.pm
parent306fcb94a5cd33c20630912327ff7230357f1c6c (diff)
downloaddrakx-149ca71e19a3b0b019ab13d6366f201ad5bdd7d7.tar
drakx-149ca71e19a3b0b019ab13d6366f201ad5bdd7d7.tar.gz
drakx-149ca71e19a3b0b019ab13d6366f201ad5bdd7d7.tar.bz2
drakx-149ca71e19a3b0b019ab13d6366f201ad5bdd7d7.tar.xz
drakx-149ca71e19a3b0b019ab13d6366f201ad5bdd7d7.zip
- bootloader-config
o handle new naming of vmlinuz flavors: vmlinuz-<version>-<flavor>-Xmdv instead of vmlinuz-<version>-Xmdv<flavor> o always use "linux" short name instead of "linux-<flavor>" (since the long name is quite nice nowadays) - drop now unneeded special case for kernel-tmb
Diffstat (limited to 'perl-install/bootloader.pm')
-rw-r--r--perl-install/bootloader.pm10
1 files changed, 5 insertions, 5 deletions
diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm
index 12fea67a7..302544acb 100644
--- a/perl-install/bootloader.pm
+++ b/perl-install/bootloader.pm
@@ -43,7 +43,10 @@ sub vmlinuz2kernel_str {
{
basename => $basename,
version => $version,
- $version =~ /(.*md[kv])-?(.*)/ ? (ext => $2, version_no_ext => $1) : (version_no_ext => $version),
+ $version =~ /(.*)-(\D.*)-(\d+md[kv])$/ ? #- eg: 2.6.22.5-server-1mdv
+ (ext => $2, version_no_ext => "$1-$3") :
+ $version =~ /(.*md[kv])-?(.*)/ ? #- (old) eg: 2.6.17-13mdventerprise
+ (ext => $2, version_no_ext => $1) : (version_no_ext => $version),
};
}
@@ -83,8 +86,7 @@ sub kernel_str2label {
my ($kernel, $o_use_long_name) = @_;
my $base = $kernel->{basename} eq 'vmlinuz' ? 'linux' : $kernel->{basename};
$o_use_long_name || $kernel->{use_long_name} ?
- sanitize_ver($base, $kernel) :
- $kernel->{ext} ? "$base-" . short_ext($kernel) : $base;
+ sanitize_ver($base, $kernel) : $base;
}
sub get {
@@ -857,8 +859,6 @@ sub sanitize_ver {
my $v = $kernel_str->{version_no_ext};
if ($v =~ s/-\d+\.mm\././) {
$name = join(' ', grep { $_ } $name, 'multimedia');
- } elsif ($v =~ s/-(desktop|server|laptop)-/-/) {
- $name = join(' ', grep { $_ } $name, $1);
}
$v =~ s!md[kv]$!!;