[SCM] Debian package checker branch, master, updated. 2.5.4-119-gc34db90
The following commit has been merged in the master branch:
commit c34db90f190ddcdf0b25d9f7a635a9524d1c6bbe
Author: Luca Falavigna <dktrkranz@debian.org>
Date: Sat Jan 28 16:35:15 2012 +0100
Implemented "soruce-contains-waf-binary" tag
Acked-by: Niels Thykier <niels@thykier.net>
diff --git a/checks/cruft b/checks/cruft
index ecd647e..c5e7994 100644
--- a/checks/cruft
+++ b/checks/cruft
@@ -151,6 +151,8 @@ for my $file (keys(%$file_info)) {
tag 'source-contains-prebuilt-binary', $file;
} elsif ($file_info->{$file} =~ m/\b(?:PE(?:32|64)|COFF executable)\b/) {
tag 'source-contains-prebuilt-windows-binary', $file;
+ } elsif ($file_info->{$file} =~ m/data/ and $file =~ /\bwaf$/) {
+ tag 'source-contains-waf-binary', $file;
}
}
diff --git a/checks/cruft.desc b/checks/cruft.desc
index 2093f72..7ed6828 100644
--- a/checks/cruft.desc
+++ b/checks/cruft.desc
@@ -429,6 +429,21 @@ Info: The source tarball contains a prebuilt binary for Microsoft Windows.
the upstream distribution instead. If not, you may want to ask upstream
to provide source-only tarballs.
+Tag: source-contains-waf-binary
+Severity: important
+Certainty: certain
+Info: The source tarball contains a waf binary. This file is a Python
+ script with an embedded bzip2 archive, which is uncompressed and unpacked
+ at runtime.
+ .
+ Although corresponding sources can be easily extracted, FTP Team does not
+ consider waf binary as the preferred form of modification; it should be
+ provided unpacked instead, or completely removed, if possible.
+ .
+ You might want to follow these guidelines to obtain an unpacked waf:
+ http://wiki.debian.org/UnpackWaf
+Ref: http://wiki.debian.org/UnpackWaf, #654523
+
Tag: tar-errors-from-source
Severity: normal
Certainty: wild-guess
diff --git a/debian/changelog b/debian/changelog
index 691903a..3159f34 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -12,6 +12,7 @@ lintian (2.5.5) UNRELEASED; urgency=low
- package-uses-dh-exec-but-lacks-build-depends
- preinst-uses-dpkg-maintscript-helper-without-predepends
- shlib-in-multi-arch-foreign-package
+ - source-contains-waf-binary
- syntax-error-in-control-file
- syntax-error-in-debconf-template
+ Removed:
@@ -31,13 +32,15 @@ lintian (2.5.5) UNRELEASED; urgency=low
to David Bremner for the report. (Closes: #652602)
+ [NT] Emit a tag if there is a syntax error in d/control rather
than just aborting the rest of the check.
- * checks/cruft:
+ * checks/cruft{,.desc}:
+ [NT] Added dh-autoreconf as a build-depends alternative to
libtool for suppressing ancient-libtool warning. Thanks to
Felix Geyer for the report. (Closes: #650325)
+ [NT] Accepted patch from Paul Wise to detect COFF object
files as Win32 binaries.
+ [NT] Properly handle unpacked being a symlink.
+ + [NT] Accepted patch from Luca Falavigna to detect waf files
+ with a binary payload. (Closes: #654523)
* checks/debconf:
+ [RA] Recognize Perl uses of debconf templates via metaget or
settitle.
diff --git a/t/tests/cruft-contains-waf/desc b/t/tests/cruft-contains-waf/desc
new file mode 100644
index 0000000..53d9fce
--- /dev/null
+++ b/t/tests/cruft-contains-waf/desc
@@ -0,0 +1,6 @@
+Testname: cruft-contains-waf
+Sequence: 6000
+Version: 1.0-1
+Type: non-native
+Description: Check for sources with waf
+Test-For: source-contains-waf-binary
diff --git a/t/tests/cruft-contains-waf/pre_upstream b/t/tests/cruft-contains-waf/pre_upstream
new file mode 100755
index 0000000..12db812
--- /dev/null
+++ b/t/tests/cruft-contains-waf/pre_upstream
@@ -0,0 +1,18 @@
+#!/bin/sh
+#
+# Time to create a waf binary...
+
+set -e
+
+dir="$1"
+
+cd "$dir"
+
+tar cjf waf-bin.tar.bz2 some-source.c
+cp waf.in waf
+echo "#==>" >> waf
+echo -n "#" >> waf
+perl -pe 's,\n,\#\*,go; s,\r,\#\%,go;' waf-bin.tar.bz2 >> waf
+echo >> waf
+echo "#<==" >> waf
+rm waf-bin.tar.bz2
diff --git a/t/tests/cruft-contains-waf/tags b/t/tests/cruft-contains-waf/tags
new file mode 100644
index 0000000..ba585d6
--- /dev/null
+++ b/t/tests/cruft-contains-waf/tags
@@ -0,0 +1 @@
+E: cruft-contains-waf source: source-contains-waf-binary waf
diff --git a/t/tests/cruft-contains-waf/upstream/some-source.c b/t/tests/cruft-contains-waf/upstream/some-source.c
new file mode 100644
index 0000000..6691108
--- /dev/null
+++ b/t/tests/cruft-contains-waf/upstream/some-source.c
@@ -0,0 +1,5 @@
+int fun(int a) {
+ /* There is a valid use for this... probably */
+ return (a * a) >> a;
+}
+
diff --git a/t/tests/cruft-contains-waf/upstream/waf.in b/t/tests/cruft-contains-waf/upstream/waf.in
new file mode 100644
index 0000000..1404a57
--- /dev/null
+++ b/t/tests/cruft-contains-waf/upstream/waf.in
@@ -0,0 +1,13 @@
+#!/usr/bin/python
+# encoding: ISO-8859-1
+#
+
+# We just do a little python... for the show
+
+import os, sys
+if sys.hexversion<0x203000f: raise ImportError("Waf requires python >= 2.3")
+ # and we are pretending to be a waf script
+
+# okay, thats enough... below we will include a binary tarball...
+# That is as fun as it sounds (which is to say not a lot).
+
--
Debian package checker
Reply to: