diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2006-11-09 15:43:32 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2006-11-09 15:43:32 +0000 |
commit | 5e3aee184296b595f781dae5a7087d6c113fcefa (patch) | |
tree | f7c66aef62b7d29ef4502ec5b75a170d4c57d856 /urpm.pm | |
parent | 5ac0c63afbd2d55c7a1c271e032439c0955034a7 (diff) | |
download | urpmi-5e3aee184296b595f781dae5a7087d6c113fcefa.tar urpmi-5e3aee184296b595f781dae5a7087d6c113fcefa.tar.gz urpmi-5e3aee184296b595f781dae5a7087d6c113fcefa.tar.bz2 urpmi-5e3aee184296b595f781dae5a7087d6c113fcefa.tar.xz urpmi-5e3aee184296b595f781dae5a7087d6c113fcefa.zip |
restore uniq() (i sucks)
Diffstat (limited to 'urpm.pm')
-rw-r--r-- | urpm.pm | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -3270,6 +3270,8 @@ sub unselected_packages { grep { $state->{rejected}{$_}{backtrack} } keys %{$state->{rejected} || {}}; } +sub uniq { my %l; $l{$_} = 1 foreach @_; grep { delete $l{$_} } @_ } + sub translate_why_unselected { my ($urpm, $state, @l) = @_; @@ -3279,12 +3281,12 @@ sub translate_why_unselected { my @unsatisfied = @{$rb->{unsatisfied} || []}; my $s = join ", ", ( (map { N("due to missing %s", $_) } @froms), - (map { N("due to unsatisfied %s", $_) } uniq map { + (map { N("due to unsatisfied %s", $_) } uniq(map { #- XXX in theory we shouldn't need this, dependencies (and not ids) should #- already be present in @unsatisfied. But with biarch packages this is #- not always the case. /\D/ ? $_ : scalar($urpm->{depslist}[$_]->fullname); - } @unsatisfied), + } @unsatisfied)), $rb->{promote} && !$rb->{keep} ? N("trying to promote %s", join(", ", @{$rb->{promote}})) : @{[]}, $rb->{keep} ? N("in order to keep %s", join(", ", @{$rb->{keep}})) : @{[]}, ); |