summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS2
-rw-r--r--urpm/install.pm5
2 files changed, 6 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 4fa6feb5..cc35af74 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,7 @@
- add --deploops & --debug-librpm to bash completion
- unset LD_PRELOAD in chroot (eg: for eatmydata)
+- use new "elem" callback
+ (need URPM >= 5.07)
Version 8.101 - 9 October 2015
diff --git a/urpm/install.pm b/urpm/install.pm
index 6f88e494..7c32fa0a 100644
--- a/urpm/install.pm
+++ b/urpm/install.pm
@@ -120,7 +120,6 @@ sub install_logger {
++$urpm->{logger_count} if $pname;
$cnt = $pname ? $urpm->{logger_count} : '-';
}
- $index++;
my $s = sprintf("%9s: %-22s", $cnt . "/" . $total_pkg, $pname);
print $s;
$s =~ / $/ or printf "\n%9s %-22s", '', '';
@@ -300,6 +299,10 @@ sub _get_callbacks {
$options->{callback_uninst} ||= $options->{verbose} >= 0 ? \&install_logger : $erase_logger;
+ $options->{callback_elem} ||= sub {
+ my (undef, undef, undef, undef, $idx, undef) = @_;
+ $index = $idx;
+ };
$options->{callback_error} ||= sub {
my ($urpm, undef, $id, $subtype, undef, undef, $fullname) = @_;
$urpm->{error}("ERROR: '$subtype' failed for $fullname");