summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@mandriva.com>2010-04-23 15:48:42 +0000
committerChristophe Fergeau <cfergeau@mandriva.com>2010-04-23 15:48:42 +0000
commit680bcfe1610e832166e9812c3ea58837e27fdc1d (patch)
tree131e269a0a0f14256363d1c9bcf7d888fd6bc08c
parentf3498bbcc21adde170cd5c8255b99a7eeb38d399 (diff)
downloadurpmi-680bcfe1610e832166e9812c3ea58837e27fdc1d.tar
urpmi-680bcfe1610e832166e9812c3ea58837e27fdc1d.tar.gz
urpmi-680bcfe1610e832166e9812c3ea58837e27fdc1d.tar.bz2
urpmi-680bcfe1610e832166e9812c3ea58837e27fdc1d.tar.xz
urpmi-680bcfe1610e832166e9812c3ea58837e27fdc1d.zip
when using --update, allow to get dependencies from non-update media
Fixes #51268
-rw-r--r--NEWS3
-rw-r--r--urpm/media.pm14
2 files changed, 14 insertions, 3 deletions
diff --git a/NEWS b/NEWS
index a94ce870..5ad9c2a0 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,8 @@
- urpmi.addmedia:
o disable non-free repository by default for Free edition (#40033)
+-urpmi:
+ o when using --update, allow package dependencies to be fetched from
+ non-update media (#51268)
Version 6.34 - 25 January 2010
diff --git a/urpm/media.pm b/urpm/media.pm
index c045d8b8..b7b7f6cb 100644
--- a/urpm/media.pm
+++ b/urpm/media.pm
@@ -645,6 +645,14 @@ sub configure {
$_->{searchmedia} = 1;
}
}
+ if ($options{update}) {
+ foreach (grep { !$_->{ignore} && ($_->{update}) } @{$urpm->{media} || []}) {
+ #- Ensure update media are selected
+ $_->{modified} = 1;
+ _tempignore($_, 0);
+ $_->{searchmedia} = 1;
+ }
+ }
if ($options{excludemedia}) {
delete $_->{modified} foreach @{$urpm->{media} || []};
foreach (select_media_by_name($urpm, [ split /,/, $options{excludemedia} ])) {
@@ -660,7 +668,7 @@ sub configure {
}
_auto_update_media($urpm, %options);
- _pick_mirror_if_needed($urpm, $_, '') foreach non_ignored_media($urpm, $options{update});
+ _pick_mirror_if_needed($urpm, $_, '') foreach non_ignored_media($urpm);
parse_media($urpm, \%options) if !$options{nodepslist};
@@ -679,7 +687,7 @@ sub _auto_update_media {
$options{callback} = delete $options{download_callback};
foreach (grep { _is_remote_virtual($_) || $urpm->{options}{'auto-update'} }
- non_ignored_media($urpm, $options{update})) {
+ non_ignored_media($urpm)) {
_update_medium($urpm, $_, %options);
}
}
@@ -702,7 +710,7 @@ sub all_media_to_update {
sub parse_media {
my ($urpm, $options) = @_;
- foreach (non_ignored_media($urpm, $options->{update})) {
+ foreach (non_ignored_media($urpm)) {
delete @$_{qw(start end)};
_parse_synthesis_or_ignore($urpm, $_, $options->{callback});