lots of pdl messages on Xenial Negative repeat count does nothing

Bug #1695763 reported by jan
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pdl (Ubuntu)
New
Undecided
Unassigned

Bug Description

Perl 5.21.x and higher (as included in xenial) is not compatible with pdl < 0.016.
Therefore, many programs with pdl run on xenial will print lots of lines "Negative repeat count does nothing".

https://rt.cpan.org/Public/Bug/Display.html?id=100228

Could the pdl in xenial LTS be upgraded to 0.016 to make it workable ?

Revision history for this message
jan (jan-ubuntu-h-i-s) wrote :

Naively installing the yakkety package does not work.
5.22.1-9 It would help if the perl depencency would just be a little lower.
And there is a problem with install-docs when trying that on xenial.

sudo dpkg --install pdl_2.016-4_amd64.deb

(Reading database ... 1136894 files and directories currently installed.)
Preparing to unpack pdl_2.016-4_amd64.deb ...
Unpacking pdl (1:2.016-4) over (1:2.007-5) ...
dpkg: dependency problems prevent configuration of pdl:
 pdl depends on perl (>= 5.22.2-1); however:
  Version of perl on system is 5.22.1-9.
 pdl depends on perlapi-5.22.2; however:
  Package perlapi-5.22.2 is not installed.

dpkg: error processing package pdl (--install):
 dependency problems - leaving unconfigured
Processing triggers for doc-base (0.10.7) ...
Processing 1 changed doc-base file...
Error in `/usr/share/doc-base/pdl', line 14: all `Format' sections are invalid.
Note: `install-docs --verbose --check file_name' may give more details about the above error.
Registering documents with scrollkeeper...
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for menu (2.1.47ubuntu1) ...
Errors were encountered while processing:
 pdl

Revision history for this message
jan (jan-ubuntu-h-i-s) wrote :

Alternatively, change the following code:

diff -r1.1 /usr/lib/x86_64-linux-gnu/perl5/5.22/PDL/Core.pm
1546,1547c1546,1549
< my($s) = ',' x ( ($dim > $pdl->getndims) ? ($pdl->getndims) : ($dim) );
< $s .= '*1,' x ( $dim-$pdl->getndims );
---
> # Avoid negative repeat count warning that came with 5.21 and later.
> my $dim_diff = $dim - $pdl->getndims;
> my($s) = ',' x ( $dim_diff > 0 ? $pdl->getndims : $dim );
> $s .= '*1,' x ( $dim_diff > 0 ? $dim_diff : 0 );

Revision history for this message
Ed J (mohawk2) wrote :

This patch was in PDL as of 26 Feb 2015, and main-released to CPAN as 2.008 on 24 May 2015. Seeing as it's 2021 and CPAN's PDL is 2.038, can this bug be closed?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.