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

Bug#660845: [PATCH] lintian: false positive codeless-jar warning with javadoc jar files



Hello,

I made a patch for this bug, please review it.

Thanks,
Ludovic
>From 100949797a8a468c6f803db966e60fc5f19702bb Mon Sep 17 00:00:00 2001
From: Ludovic Claude <ludovic.claude@laposte.net>
Date: Thu, 3 May 2012 23:32:04 +0200
Subject: [PATCH] checks/java:   + Ignore javadoc jars for the codeless-jar
 tag. (Closes: #660845)

---
 checks/java      |    4 +++-
 debian/changelog |    2 ++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/checks/java b/checks/java
index 2f8a893..2b7a5b9 100644
--- a/checks/java
+++ b/checks/java
@@ -97,7 +97,9 @@ for my $jar_file (sort keys %{$java_info}) {
 
             # Eclipse / OSGi bundles are sometimes source bundles
             #   these do not ship classes but java files and other sources.
-            if ($bsname !~ m/\.source$/o || $cp) {
+            # Javadoc jars deployed in the Maven repository also do not ship
+            #   classes but HTML files, images and CSS files
+            if (($bsname !~ m/\.source$/o && $jar_file !~ m#^usr/share/maven-repo/.*-javadoc\.jar#) || $cp) {
                 tag 'codeless-jar', $jar_file;
             }
         }
diff --git a/debian/changelog b/debian/changelog
index 01b579c..fbd5137 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -101,6 +101,8 @@ lintian (2.5.7) UNRELEASED; urgency=low
       raster images in "scalable" icon directories.  Thanks to
       Paul Wise for the report and Felix Geyer for the patches.
       (Closes: #628189)
+  * checks/java:
+    + Ignore javadoc jars for the codeless-jar tag. (Closes: #660845)
   * checks/lintian.desc:
     + [NT] Updated the description of the override tags.
   * checks/manpages{,.desc}:
-- 
1.7.9.5


Reply to: