The following commit has been merged in the master branch:
commit 3f8f43ff03c418ed5d388f6f273ff98e7d4fb243
Author: Dominic Hargreaves <[email protected]>
Date:   Sun Nov 20 14:03:43 2011 +0100

    Fix perl4 lib checks to allow perl (<< 5.12.3-7)
    
    Lintian's advice with this tag is to include a dependency on
    libperl4-corelibs-perl | perl (<< 5.12.3-7).
    
    Acked-by: Niels Thykier <[email protected]>

diff --git a/checks/files b/checks/files
index 2680b99..e4206a2 100644
--- a/checks/files
+++ b/checks/files
@@ -820,7 +820,7 @@ foreach my $file (@{$info->sorted_index}) {
     # we do the same check on perl scripts in checks/scripts
     {
         my $dep = $info->relation('strong');
-        if ($index_info->{type} =~ m/^[-h]/o && $file =~ m,\.pm$, && 
!$dep->implies('libperl4-corelibs-perl')) {
+        if ($index_info->{type} =~ m/^[-h]/o && $file =~ m,\.pm$, && 
!$dep->implies ('libperl4-corelibs-perl | perl (<< 5.12.3-7)')) {
             open (PM, '<', $info->unpacked($file)) or fail("cannot open .pm 
file: $!");
             while (<PM>) {
                 if 
(/(?:do|require)\s+(?:'|")(abbrev|assert|bigfloat|bigint|bigrat|cacheout|complete|ctime|dotsh|exceptions|fastcwd|find|finddepth|flush|getcwd|getopt|getopts|hostname|importenv|look|newgetopt|open2|open3|pwd|shellwords|stat|syslog|tainted|termcap|timelocal|validate)\.pl(?:'|")/)
 {
diff --git a/checks/scripts b/checks/scripts
index 504d718..46bc373 100644
--- a/checks/scripts
+++ b/checks/scripts
@@ -452,7 +452,8 @@ for my $filename (sort keys %{$info->scripts}) {
     }
 
     # Check for obsolete perl libraries
-    if ($base eq 'perl' && !$str_deps->implies('libperl4-corelibs-perl')) {
+    if ($base eq 'perl' &&
+             !$str_deps->implies ('libperl4-corelibs-perl | perl (<< 
5.12.3-7)')) {
         open(FH, '<', $path) or fail("could not open script $path");
         while (<FH>) {
             if 
(/(?:do|require)\s+(?:'|")(abbrev|assert|bigfloat|bigint|bigrat|cacheout|complete|ctime|dotsh|exceptions|fastcwd|find|finddepth|flush|getcwd|getopt|getopts|hostname|importenv|look|newgetopt|open2|open3|pwd|shellwords|stat|syslog|tainted|termcap|timelocal|validate)\.pl(?:'|")/)
 {
diff --git a/debian/changelog b/debian/changelog
index 18dc477..a5bc215 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -77,6 +77,8 @@ lintian (2.5.4) UNRELEASED; urgency=low
     + [JW,NT] Check that gzip files are compressed with -n in
       "Multi-Arch: same" packages.  (Closes: #649329)
       packages.
+    + [NT] Corrected perl4 check, thanks to Dominic Hargreaves for the
+      report and the patch.
   * checks/init.d{,.desc}:
     + [NT] Applied patch from Peter Eisentraut to detect init.d scripts
       without support for the optional "status" option.
@@ -96,6 +98,8 @@ lintian (2.5.4) UNRELEASED; urgency=low
       checks.  ERB is a Ruby templating language, so these will probably
       have mixed shell and Ruby code and may not be executable.  Thanks,
       Laurent Arnoud.
+    + [NT] Corrected perl4 check, thanks to Dominic Hargreaves for the
+      report and the patch.  (Closes: #648532)
   * checks/source-copyright:
     + [JW] Added some more DEP-5 URLs.  (Closes: #642027)
     + [JW] Improved the wording of the extra information for the tag
diff --git a/t/tests/files-uses-perl4-libs-with-dep/debian/debian/control.in 
b/t/tests/files-uses-perl4-libs-with-dep/debian/debian/control.in
index 426e421..475f52a 100644
--- a/t/tests/files-uses-perl4-libs-with-dep/debian/debian/control.in
+++ b/t/tests/files-uses-perl4-libs-with-dep/debian/debian/control.in
@@ -7,7 +7,8 @@ Build-Depends: debhelper (>= 7.0.50~)
 
 Package: {$srcpkg}
 Architecture: {$architecture}
-Depends: $\{shlibs:Depends\}, $\{misc:Depends\}, libperl4-corelibs-perl
+Depends: $\{shlibs:Depends\}, $\{misc:Depends\},
+ libperl4-corelibs-perl | perl (<< 5.12.3-7)
 Description: {$description}
  This is a test package designed to exercise some feature or tag of
  Lintian.  It is part of the Lintian test suite and may do very odd
diff --git a/t/tests/scripts-uses-perl4-libs-with-dep/debian/debian/control.in 
b/t/tests/scripts-uses-perl4-libs-with-dep/debian/debian/control.in
index c5d2e1c..b3a9738 100644
--- a/t/tests/scripts-uses-perl4-libs-with-dep/debian/debian/control.in
+++ b/t/tests/scripts-uses-perl4-libs-with-dep/debian/debian/control.in
@@ -7,7 +7,8 @@ Build-Depends: debhelper (>= 7.0.50~), perl
 
 Package: {$srcpkg}
 Architecture: {$architecture}
-Depends: $\{shlibs:Depends\}, $\{misc:Depends\}, libperl4-corelibs-perl
+Depends: $\{shlibs:Depends\}, $\{misc:Depends\},
+ libperl4-corelibs-perl | perl (<< 5.12.3-7)
 Description: {$description}
  This is a test package designed to exercise some feature or tag of
  Lintian.  It is part of the Lintian test suite and may do very odd

-- 
Debian package checker


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]
Archive: http://lists.debian.org/[email protected]

Reply via email to