[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] Debian package checker branch, master, updated. 2.2.13-50-gbd5784d



The following commit has been merged in the master branch:
commit 47b2542ae897f1505f048c299c5fa9f0c1e19bc4
Author: Russ Allbery <rra@debian.org>
Date:   Sat Aug 15 19:06:49 2009 -0700

    Check for a dependency on install-info
    
    * checks/infofiles{,.desc}:
      + [RA] Check that packages with info files depend on dpkg or
        install-info as recommended by Policy 5.8.3.

diff --git a/checks/infofiles b/checks/infofiles
index cd12bc1..8c0dc5c 100644
--- a/checks/infofiles
+++ b/checks/infofiles
@@ -36,6 +36,7 @@ my $type = shift;
 my $info = shift;
 
 my %missing_section;
+my $has_info_file;
 
 # Read package contents...
 foreach my $file (sort keys %{$info->index}) {
@@ -51,6 +52,9 @@ foreach my $file (sort keys %{$info->index}) {
     # the files check.
     next if $fname =~ /^dir(?:\.old)?(?:\.gz)?/;
 
+    # Note that this package contains at least one info file.
+    $has_info_file = 1;
+
     # Analyze the file names making sure the documents are named properly.
     # Note that Emacs 22 added support for images in info files, so we have to
     # accept those and ignore them.  Just ignore .png files for now.
@@ -105,6 +109,16 @@ foreach my $file (sort keys %{$info->index}) {
     }
 }
 
+# If there's at least one info file in the package, the package should depend
+# on dpkg (>= 1.15.4) | install-info to ensure the dir file is properly
+# handled on partial upgrades.
+if ($has_info_file) {
+    my $depends = $info->relation('depends');
+    unless ($depends->implies('dpkg (>= 1.15.4) | install-info')) {
+	tag 'missing-dependency-on-install-info';
+    }
+}
+
 }
 
 1;
diff --git a/checks/infofiles.desc b/checks/infofiles.desc
index aa8375b..79fd436 100644
--- a/checks/infofiles.desc
+++ b/checks/infofiles.desc
@@ -61,3 +61,13 @@ Info: This info document has no directory entry.  This is text between
  to the texinfo source so that the generated info file will contain an
  appropriate entry.  You will have to ensure that the build process builds
  new info files rather than using ones built by upstream.
+
+Tag: missing-dependency-on-install-info
+Severity: normal
+Certainty: possible
+Info: This package appears to contain at least one info document but does
+ not depend on <tt>dpkg (>= 1.15.4) | install-info</tt> as recommended by
+ Policy.  This dependency is needed for the transition to triggerized
+ install-info to correctly build the info directory during partial
+ upgrades from lenny.
+Ref: policy 12.2
diff --git a/debian/changelog b/debian/changelog
index af3416a..68274df 100755
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,7 @@ lintian (2.2.14) UNRELEASED; urgency=low
     + Added:
       - debhelper-overrides-need-versioned-build-depends
       - maintainer-script-modifies-ld-so-conf
+      - missing-dependency-on-install-info
       - multiple-distributions-in-changes-file
       - patch-system-but-no-source-readme
       - package-modifies-ld.so-search-path
@@ -40,8 +41,10 @@ lintian (2.2.14) UNRELEASED; urgency=low
     + [RA] Remove the check for x11-common pre-depends before installing
       files in /usr/{include,lib}/X11.  Policy 3.8.3 removes this
       requirement.
-  * checks/infofiles.desc:
+  * checks/infofiles{,.desc}:
     + [RA] Add missing leading * to example info directory entry.
+    + [RA] Check that packages with info files depend on dpkg or
+      install-info as recommended by Policy 5.8.3.
   * checks/lintian.desc:
     + [RA] Expand multiple-distributions-in-changes-file description and
       add a reference to the Policy section.  Change certainty to
diff --git a/t/tests/infofiles-general/desc b/t/tests/infofiles-general/desc
index 69b01f6..d4c7b20 100644
--- a/t/tests/infofiles-general/desc
+++ b/t/tests/infofiles-general/desc
@@ -9,4 +9,5 @@ Test-For:
  info-document-not-compressed
  info-document-not-compressed-with-gzip
  info-document-not-compressed-with-max-compression
+ missing-dependency-on-install-info
 References: Bug#534640
diff --git a/t/tests/infofiles-general/tags b/t/tests/infofiles-general/tags
index 96a28fc..8c86f08 100644
--- a/t/tests/infofiles-general/tags
+++ b/t/tests/infofiles-general/tags
@@ -7,3 +7,4 @@ E: infofiles-general: info-document-not-compressed-with-gzip usr/share/info/foo-
 E: infofiles-general: info-document-not-compressed-with-max-compression usr/share/info/foo-nomax.gz
 W: infofiles-general: gz-file-not-gzip usr/share/info/foo-nogz.gz
 W: infofiles-general: info-document-has-wrong-extension usr/share/info/bar.newinfo.gz
+W: infofiles-general: missing-dependency-on-install-info

-- 
Debian package checker


Reply to: