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

[lintian] 03/05: Detect silverlight prebuilt object



This is an automated email from the git hooks/post-receive script.

broucaries-guest pushed a commit to branch master
in repository lintian.

commit d185ef2eba3fefb0eadefff5a3a93686ecf279e6
Author: Bastien ROUCARIÈS <roucaries.bastien@gmail.com>
Date:   Sat Jan 4 23:42:13 2014 +0100

    Detect silverlight prebuilt object
    
    They are non free. Mark as it.
    
    Signed-off-by: Bastien ROUCARIÈS <roucaries.bastien+debian@gmail.com>
---
 checks/cruft.desc                           | 7 +++++++
 checks/cruft.pm                             | 4 ++++
 debian/changelog                            | 1 +
 t/tests/cruft-general-upstream/desc         | 1 +
 t/tests/cruft-general-upstream/pre_upstream | 1 +
 t/tests/cruft-general-upstream/tags         | 1 +
 6 files changed, 15 insertions(+)

diff --git a/checks/cruft.desc b/checks/cruft.desc
index e712db6..01a847e 100644
--- a/checks/cruft.desc
+++ b/checks/cruft.desc
@@ -440,6 +440,13 @@ Info: The source tarball contains a prebuilt java object.  They are usually
  directory first.  You may want to report this as an upstream bug, in case
  there is no sign that this was intended.
 
+Tag: source-contains-prebuilt-silverlight-object
+Severity: serious
+Certainty: possible
+Info: The source tarball contains a prebuilt silverlight object.
+ This file are not buildable under debian and need non free
+ dependencies. This must be completely removed.
+
 Tag: source-contains-prebuilt-windows-binary
 Severity: pedantic
 Certainty: certain
diff --git a/checks/cruft.pm b/checks/cruft.pm
index 896c9ca..7f519c6 100644
--- a/checks/cruft.pm
+++ b/checks/cruft.pm
@@ -436,6 +436,10 @@ sub find_cruft {
         } elsif ($file_info =~ m/^Zip archive data/) {
             if ($name =~ m/\.jar$/i) {
                 tag 'source-contains-prebuilt-java-object', $name;
+            } elsif ($name =~ m/\.xac$/i) {
+                unless ($info->is_non_free) {
+                    tag 'source-contains-prebuilt-silverlight-object', $name;
+                }
             }
         } elsif ($basename =~ /\bwaf$/) {
             my $path   = $info->unpacked($entry);
diff --git a/debian/changelog b/debian/changelog
index 637f31c..3470cf5 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,7 @@ lintian (2.5.21) UNRELEASED; urgency=medium
     + [BR] Detect non free rfc (Closes: #365213).
     + [BR] Check md5sums on source package.
     + [BR] Detect prebuilt jar file.
+    + [BR] Detect prebuilt silverlight file.
 
   * checks/changelog-file.{desc,pm}:
     + [BR] Warn when an upload erroneously targetted at distribution that
diff --git a/t/tests/cruft-general-upstream/desc b/t/tests/cruft-general-upstream/desc
index 449bd53..70933f7 100644
--- a/t/tests/cruft-general-upstream/desc
+++ b/t/tests/cruft-general-upstream/desc
@@ -17,6 +17,7 @@ Test-For:
  source-contains-hg-control-dir
  source-contains-hg-tags-file
  source-contains-prebuilt-java-object
+ source-contains-prebuilt-silverlight-object
  source-contains-prebuilt-windows-binary
  source-contains-svk-commit-file
  source-contains-svn-commit-file
diff --git a/t/tests/cruft-general-upstream/pre_upstream b/t/tests/cruft-general-upstream/pre_upstream
index 0a2e10e..8c3497f 100755
--- a/t/tests/cruft-general-upstream/pre_upstream
+++ b/t/tests/cruft-general-upstream/pre_upstream
@@ -33,3 +33,4 @@ echo 'configure-generated-file-in-source' > "${dir}/config.cache"
 
 printf "MZ\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\x3c" > "${dir}/fake-win32-bin.exe"
 printf "PK\003\004" > "${dir}/fake.jar"
+printf "PK\003\004" > "${dir}/fakesilverlight.xac"
diff --git a/t/tests/cruft-general-upstream/tags b/t/tests/cruft-general-upstream/tags
index 89eaf39..5c69e3a 100644
--- a/t/tests/cruft-general-upstream/tags
+++ b/t/tests/cruft-general-upstream/tags
@@ -1,3 +1,4 @@
+E: cruft-general-upstream source: source-contains-prebuilt-silverlight-object fakesilverlight.xac
 P: cruft-general-upstream source: debian-watch-may-check-gpg-signature
 P: cruft-general-upstream source: source-contains-arch-control-dir {arch}
 P: cruft-general-upstream source: source-contains-arch-inventory-file .arch-inventory

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git


Reply to: