aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-05-12 07:34:56 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-05-12 07:34:56 +0000
commitba2a9b2771f8fbe79bd20342c1e0ef5dc426b136 (patch)
tree137bdd72761039aa01a41f0997fd85522faa2e8c
parentcc398357e64ab93566d2591d2f0154ebb8a7a4e8 (diff)
downloadrpmdrake-ba2a9b2771f8fbe79bd20342c1e0ef5dc426b136.tar
rpmdrake-ba2a9b2771f8fbe79bd20342c1e0ef5dc426b136.tar.gz
rpmdrake-ba2a9b2771f8fbe79bd20342c1e0ef5dc426b136.tar.bz2
rpmdrake-ba2a9b2771f8fbe79bd20342c1e0ef5dc426b136.tar.xz
rpmdrake-ba2a9b2771f8fbe79bd20342c1e0ef5dc426b136.zip
Rework the algorithm to compute upgrades to be more similar to urpmi
-rwxr-xr-xrpmdrake11
1 files changed, 10 insertions, 1 deletions
diff --git a/rpmdrake b/rpmdrake
index ff34be30..d75dd871 100755
--- a/rpmdrake
+++ b/rpmdrake
@@ -1299,8 +1299,17 @@ Then, restart %s.", $rpmdrake::myname_update)), myexit(-1);
@update_medias = grep { !$_->{ignore} && $_->{update} } @{$urpm->{media}};
check_update_media_version($urpm, @update_medias);
- $urpm->compute_installed_flags(db());
+ my $requested = {};
+ $urpm->request_packages_to_upgrade(
+ db(),
+ {}, #- $state,
+ $requested,
+ requested => undef,
+ start => 0,
+ end => $#{$urpm->{depslist}},
+ );
+ $urpm->{depslist}[$_]->set_flag_installed for keys %$requested; #- pretend it's installed
foreach my $pkg (@{$urpm->{depslist}}) {
$pkg->flag_upgrade or next;
my $selected = 0;