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

lintian: r853 - in trunk: checks debian testset testset/maintainer-scripts/debian



Author: rra
Date: 2007-04-23 01:26:57 +0200 (Mon, 23 Apr 2007)
New Revision: 853

Modified:
   trunk/checks/scripts
   trunk/checks/scripts.desc
   trunk/debian/changelog
   trunk/testset/maintainer-scripts/debian/postinst
   trunk/testset/tags.maintainer-scripts
Log:
* checks/scripts{.desc,}:
  + [RA] Packages calling update-xmlcatalog must depend on xml-core.
    Also avoid false positives when a package itself provides the
    program its maintainer scripts use.  Thanks, Daniel Leidert.
    (Closes: #419461)

Modified: trunk/checks/scripts
===================================================================
--- trunk/checks/scripts	2007-04-22 23:14:59 UTC (rev 852)
+++ trunk/checks/scripts	2007-04-22 23:26:57 UTC (rev 853)
@@ -173,10 +173,11 @@
 # reported is maintainer-script-needs-depends-on-%s, so be sure to update
 # scripts.desc when adding a new rule.
 my @depends_needed = (
-	[ adduser                => '\badduser\b'        ],
-	[ 'gconf2 (>= 2.10.1-2)' => '\bgconf-schemas\b'  ],
-	[ $update_inetd		 => '\bupdate-inetd\b'	 ],
-	[ ucf                    => '\bucf\s'            ],
+	[ adduser		 => '\badduser\b'	    ],
+	[ 'gconf2 (>= 2.10.1-2)' => '\bgconf-schemas\b'	    ],
+	[ $update_inetd		 => '\bupdate-inetd\b'	    ],
+	[ ucf			 => '\bucf\s'		    ],
+	[ 'xml-core'		 => '\bupdate-xmlcatalog\b' ],
 );
 
 my %executable = ();
@@ -596,7 +597,7 @@
 	} else {
 	    for my $rule (@depends_needed) {
 		my ($package, $regex) = @$rule;
-		if (/$regex/ && ! $warned{$package}) {
+		if ($pkg ne $package and /$regex/ and ! $warned{$package}) {
                     my $needed = Dep::parse($package);
                     unless (Dep::implies($deps{depends}, $needed) || Dep::implies($deps{'pre-depends'}, $needed)) {
 			my $shortpackage = $package;

Modified: trunk/checks/scripts.desc
===================================================================
--- trunk/checks/scripts.desc	2007-04-22 23:14:59 UTC (rev 852)
+++ trunk/checks/scripts.desc	2007-04-22 23:26:57 UTC (rev 853)
@@ -304,6 +304,14 @@
 Info: This script calls ucf, but the package does not depend or pre-depend
  on the ucf package.
 
+Tag: maintainer-script-needs-depends-on-xml-core
+Type: warning
+Info: This script calls update-xmlcatalog, which comes from the xml-core
+ package, but does not depend or pre-depend on xml-core.  Packages that call
+ update-xmlcatalog need to depend on xml-core.  If you are using
+ dh_installxmlcatalogs, add a dependency on ${misc:Depends} and
+ dh_installxmlcatalogs will take care of this for you.
+
 Tag: update-alternatives-remove-called-in-postrm
 Type: warning
 Info: 'update-alternatives --remove <alternative> foo' is called in the

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2007-04-22 23:14:59 UTC (rev 852)
+++ trunk/debian/changelog	2007-04-22 23:26:57 UTC (rev 853)
@@ -16,8 +16,13 @@
     + [RA] Listing a rule as a dependency of .PHONY is sufficient to mark
       it as present for GNU make and hence sufficient for Policy's
       requirement.  Thanks, Peter Eisentraut.  (Closes: #419446)
+  * checks/scripts{.desc,}:
+    + [RA] Packages calling update-xmlcatalog must depend on xml-core.
+      Also avoid false positives when a package itself provides the
+      program its maintainer scripts use.  Thanks, Daniel Leidert.
+      (Closes: #419461)
 
- -- Russ Allbery <rra@debian.org>  Sun, 22 Apr 2007 16:14:31 -0700
+ -- Russ Allbery <rra@debian.org>  Sun, 22 Apr 2007 16:22:54 -0700
 
 lintian (1.23.29) unstable; urgency=low
 

Modified: trunk/testset/maintainer-scripts/debian/postinst
===================================================================
--- trunk/testset/maintainer-scripts/debian/postinst	2007-04-22 23:14:59 UTC (rev 852)
+++ trunk/testset/maintainer-scripts/debian/postinst	2007-04-22 23:26:57 UTC (rev 853)
@@ -69,3 +69,7 @@
 
 # Calling gconf-schemas with no dependency.
 gconf-schemas --register foo.schema
+
+# Calling update-xmlcatalog with no dependency.
+update-xmlcatalog --add --type system --id "/usr/share/sgml/dtd/foo" \
+    --package maintainer-scripts --root

Modified: trunk/testset/tags.maintainer-scripts
===================================================================
--- trunk/testset/tags.maintainer-scripts	2007-04-22 23:14:59 UTC (rev 852)
+++ trunk/testset/tags.maintainer-scripts	2007-04-22 23:26:57 UTC (rev 853)
@@ -31,6 +31,7 @@
 W: maintainer-scripts: maintainer-script-hides-init-failure postinst:55
 W: maintainer-scripts: maintainer-script-needs-depends-on-gconf2 postinst
 W: maintainer-scripts: maintainer-script-needs-depends-on-ucf postinst
+W: maintainer-scripts: maintainer-script-needs-depends-on-xml-core postinst
 W: maintainer-scripts: missing-debconf-dependency
 W: maintainer-scripts: no-debconf-templates
 W: maintainer-scripts: possible-bashism-in-maintainer-script postinst:15 '. /usr/share/lintian/shell foo'



Reply to: