r53039 - in /trunk/dh-make-perl: lib/Debian/Control/FromCPAN.pm t/Control.t
dmn at users.alioth.debian.org
dmn at users.alioth.debian.org
Thu Feb 18 22:31:12 UTC 2010
Author: dmn
Date: Thu Feb 18 22:31:01 2010
New Revision: 53039
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=53039
Log:
fix the check for oldstable perl version in dependencies
Modified:
trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm
trunk/dh-make-perl/t/Control.t
Modified: trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm?rev=53039&op=diff
==============================================================================
--- trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm (original)
+++ trunk/dh-make-perl/lib/Debian/Control/FromCPAN.pm Thu Feb 18 22:31:01 2010
@@ -254,9 +254,11 @@
# perl-modules is replaced with perl
$dep->pkg('perl') if $dep->pkg eq 'perl-modules';
- my $unversioned = not $dep->ver
- or $dep->rel =~ />/
- and deb_ver_cmp( $dep->ver, $self->oldstable_perl_version ) <= 0;
+ my $unversioned = (
+ not $dep->ver
+ or $dep->rel =~ />/
+ and deb_ver_cmp( $dep->ver, $self->oldstable_perl_version ) <= 0
+ );
# perl-base is (build-)essential
return undef
Modified: trunk/dh-make-perl/t/Control.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/dh-make-perl/t/Control.t?rev=53039&op=diff
==============================================================================
--- trunk/dh-make-perl/t/Control.t (original)
+++ trunk/dh-make-perl/t/Control.t Thu Feb 18 22:31:01 2010
@@ -3,7 +3,7 @@
use strict;
use warnings;
-use Test::More tests => 19;
+use Test::More tests => 20;
use Test::Exception;
use Test::Differences;
@@ -75,3 +75,10 @@
is( $c->binary->FETCH('libtest-compile-perl')->Depends . '',
'${misc:Depends}, ${perl:Depends}, libuniversal-require-perl'
);
+
+# test pruning dependency on perl version found in oldstable
+$c->binary->FETCH('libtest-compile-perl')->Depends->add('perl (>= 5.8.8)');
+$c->prune_perl_deps;
+is( $c->binary->FETCH('libtest-compile-perl')->Depends . '',
+ '${misc:Depends}, ${perl:Depends}, libuniversal-require-perl'
+);
More information about the Pkg-perl-cvs-commits
mailing list