summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--urpm.pm13
-rwxr-xr-xurpmq2
2 files changed, 4 insertions, 11 deletions
diff --git a/urpm.pm b/urpm.pm
index 26cc2ff5..df9b94a1 100644
--- a/urpm.pm
+++ b/urpm.pm
@@ -2556,23 +2556,16 @@ sub is_delta_installable {
$v_match eq $v_installed;
}
-#- download package that may need to be downloaded.
-#- make sure header are available in the appropriate directory.
-#- change location to find the right package in the local
-#- filesystem for only one transaction.
-#- try to mount/eject removable media here.
-#- return a list of package ready for rpm.
+#- Obsolescent method.
sub download_source_packages {
my ($urpm, $local_sources, $list, %options) = @_;
my %sources = %$local_sources;
my %error_sources;
- #print STDERR "calling obsoleted method urpm::download_source_packages\n";
-
- $urpm->exlock_urpmi_db;
+ $urpm->exlock_urpmi_db unless $options{nolock};
$urpm->copy_packages_of_removable_media($list, \%sources, %options) or return;
$urpm->download_packages_of_distant_media($list, \%sources, \%error_sources, %options);
- $urpm->unlock_urpmi_db;
+ $urpm->unlock_urpmi_db unless $options{nolock};
%sources, %error_sources;
}
diff --git a/urpmq b/urpmq
index 312aa17a..0caa7bb5 100755
--- a/urpmq
+++ b/urpmq
@@ -331,7 +331,7 @@ if ($urpm::args::options{list_aliases}) {
};
$packer->extract($tmp_header_dir, @headers);
} elsif (!%downloads) {
- %downloads = $urpm->download_source_packages({}, $list, force_local => 1);
+ %downloads = $urpm->download_source_packages({}, $list, force_local => 1, nolock => $urpm::args::options{nolock});
}
}
}