summaryrefslogtreecommitdiffstats
path: root/urpm/parallel_ssh.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-07-09 21:32:45 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-07-09 21:32:45 +0000
commitb371300ca728e700a017783a410a840f2a3d3134 (patch)
tree1354e05f12c0963963043d81554918a7d58c1310 /urpm/parallel_ssh.pm
parent717e62793ef21d5e42950746106df4ab1296968b (diff)
downloadurpmi-b371300ca728e700a017783a410a840f2a3d3134.tar
urpmi-b371300ca728e700a017783a410a840f2a3d3134.tar.gz
urpmi-b371300ca728e700a017783a410a840f2a3d3134.tar.bz2
urpmi-b371300ca728e700a017783a410a840f2a3d3134.tar.xz
urpmi-b371300ca728e700a017783a410a840f2a3d3134.zip
can you believe this whole is simply duplicated? well, it is :-/
Diffstat (limited to 'urpm/parallel_ssh.pm')
-rw-r--r--urpm/parallel_ssh.pm37
1 files changed, 1 insertions, 36 deletions
diff --git a/urpm/parallel_ssh.pm b/urpm/parallel_ssh.pm
index 4119dbd8..b8ed7bbb 100644
--- a/urpm/parallel_ssh.pm
+++ b/urpm/parallel_ssh.pm
@@ -113,42 +113,7 @@ sub parallel_resolve_dependencies {
}
$parallel->{synthesis} = $synthesis;
- #- compute command line of urpm? tools.
- my $line = $parallel->{line} . ($options{auto_select} ? ' --auto-select' : '') . ($options{keep} ? ' --keep' : '');
- foreach (keys %$requested) {
- if (/\|/) {
- #- taken from URPM::Resolve to filter out choices, not complete though.
- my $packages = $urpm->find_candidate_packages($_);
- foreach (values %$packages) {
- my ($best_requested, $best);
- foreach (@$_) {
- exists $state->{selected}{$_->id} and $best_requested = $_, last;
- if ($best_requested) {
- if ($best_requested && $best_requested != $_) {
- $_->compare_pkg($best_requested) > 0 and $best_requested = $_;
- } else {
- $best_requested = $_;
- }
- } elsif ($best && $best != $_) {
- $_->compare_pkg($best) > 0 and $best = $_;
- } else {
- $best = $_;
- }
- }
- $_ = $best_requested || $best;
- }
- #- simplified choice resolution.
- my $choice = $options{callback_choices}->($urpm, undef, $state, [ values %$packages ]);
- if ($choice) {
- $urpm->{source}{$choice->id} and next; #- local packages have already been added.
- $line .= ' ' . $choice->fullname;
- }
- } else {
- my $pkg = $urpm->{depslist}[$_] or next;
- $urpm->{source}{$pkg->id} and next; #- local packages have already been added.
- $line .= ' ' . $pkg->fullname;
- }
- }
+ my $line = urpm::parallel::simple_resolve_dependencies($parallel, $urpm, $state, $requested, %options);
#- execute urpmq to determine packages to install.
my ($cont, %chosen);