Control: tag -1 patch On Sun, Dec 27, 2015 at 04:53:08PM +0200, Niko Tyni wrote: > On Sun, Dec 27, 2015 at 01:32:55PM +0200, Niko Tyni wrote: > > Package: libmarc-lint-perl > > Version: 1.49-1 > > Severity: serious > > User: debian-p...@lists.debian.org > > Usertags: autopkgtest > > > > This package fails to build on current sid/amd64. > > > > Looks like the module should be using the 'version' module to compare > > version numbers; this was presumably broken by libbusiness-isbn-perl > > 2.010-1, which entered unstable recently. > > In fact the fault is with Business::ISBN, which messed up its > version numbering, as discussed in > https://github.com/briandfoy/business-isbn/pull/2 > > Looks like Business::ISBN upstream isn't planning to fix this, > so I suppose MARC::Lint needs to adapt.
I suggest that we patch the VERSION comparisons to check for >= 2.010, add versioned dependencies to debian/control, and make libbusiness-isbn-perl Break libmarc-lint-perl (<< 1.49-2). See the attached patch. Does that make sense? -- Niko Tyni nt...@debian.org
>From 2f64649306df12e4fb41944280c9eb11e2f3fb06 Mon Sep 17 00:00:00 2001 From: Niko Tyni <nt...@debian.org> Date: Sun, 27 Dec 2015 17:02:33 +0200 Subject: [PATCH] Fix test failures due to Business::ISBN version mess Business::ISBN changed its version from 2.09 to 2.010, breaking the version comparisons in MARC::Lint. --- debian/control | 4 ++-- lib/MARC/Lint.pm | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/debian/control b/debian/control index 227a6b4..a777754 100644 --- a/debian/control +++ b/debian/control @@ -10,7 +10,7 @@ Section: perl Priority: optional Build-Depends: debhelper (>= 8) Build-Depends-Indep: perl, - libbusiness-isbn-perl, + libbusiness-isbn-perl (>= 2.010), libmarc-record-perl Standards-Version: 3.9.6 Vcs-Browser: https://anonscm.debian.org/cgit/pkg-perl/packages/libmarc-lint-perl.git @@ -22,7 +22,7 @@ Package: libmarc-lint-perl Architecture: all Depends: ${perl:Depends}, ${misc:Depends}, - libbusiness-isbn-perl, + libbusiness-isbn-perl (>= 2.010), libmarc-record-perl Description: Perl extension for checking validity of MARC records MARC::Lint is a Perl module for checking the validity of MARC records. Most diff --git a/lib/MARC/Lint.pm b/lib/MARC/Lint.pm index d96e78b..c401622 100755 --- a/lib/MARC/Lint.pm +++ b/lib/MARC/Lint.pm @@ -319,14 +319,14 @@ sub check_020 { else { if ((length ($isbnno) == 10)) { - if ($Business::ISBN::VERSION gt '2.02_01') { + if ($Business::ISBN::VERSION ge '2.010') { $self->warn( "020: Subfield a has bad checksum, $data." ) if (Business::ISBN::valid_isbn_checksum($isbnno) != 1); } #if Business::ISBN version higher than 2.02_01 elsif ($Business::ISBN::VERSION lt '2') { $self->warn( "020: Subfield a has bad checksum, $data." ) if (Business::ISBN::is_valid_checksum($isbnno) != 1); } #elsif Business::ISBN version lower than 2 else { - $self->warn( "Business::ISBN version must be below 2 or above 2.02_02." ); + $self->warn( "Business::ISBN version must be below 2 or at least 2.010." ); } #else Business::ISBN version between 2 and 2.02_02 } #if 10 digit ISBN has invalid check digit # do validation check for 13 digit isbn -- 2.6.4