summaryrefslogtreecommitdiffstats
path: root/perl-install/pkgs.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2005-08-23 15:37:00 +0000
committerPascal Rigaux <pixel@mandriva.com>2005-08-23 15:37:00 +0000
commitbcdfc7c0bbbcfbfb6afbe997ad8679daf9f81a01 (patch)
treeadcd3aa86224d39946c6ee7527eef34f59f239df /perl-install/pkgs.pm
parent7b9cf958a39177ba8526424bb01c5abcfb9b74d6 (diff)
downloaddrakx-backup-do-not-use-bcdfc7c0bbbcfbfb6afbe997ad8679daf9f81a01.tar
drakx-backup-do-not-use-bcdfc7c0bbbcfbfb6afbe997ad8679daf9f81a01.tar.gz
drakx-backup-do-not-use-bcdfc7c0bbbcfbfb6afbe997ad8679daf9f81a01.tar.bz2
drakx-backup-do-not-use-bcdfc7c0bbbcfbfb6afbe997ad8679daf9f81a01.tar.xz
drakx-backup-do-not-use-bcdfc7c0bbbcfbfb6afbe997ad8679daf9f81a01.zip
for bestKernelPackage(), sort kernels to have higher version first
Diffstat (limited to 'perl-install/pkgs.pm')
-rw-r--r--perl-install/pkgs.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/perl-install/pkgs.pm b/perl-install/pkgs.pm
index 80cbf6b9d..3ae45f94d 100644
--- a/perl-install/pkgs.pm
+++ b/perl-install/pkgs.pm
@@ -172,7 +172,9 @@ sub analyse_kernel_name {
sub packages2kernels {
my ($packages) = @_;
- map {
+ sort {
+ $a->{ext} cmp $b->{ext} || URPM::rpmvercmp($b->{version}, $a->{version});
+ } map {
if (my ($ext, $version) = analyse_kernel_name($_->name)) {
{ pkg => $_, ext => $ext, version => $version };
} else {