[SCM] Debian package checker branch, master, updated. 2.3.0-31-g2da8e01
The following commit has been merged in the master branch:
commit 2da8e01f515ae6b8153d256336767f110bf0f86d
Author: Russ Allbery <rra@debian.org>
Date: Wed Dec 30 16:00:25 2009 -0800
Check for a non-native package with a native version
* checks/cruft{,.desc}:
+ [RA] Check for a non-native package with a native version. Thanks,
Andreas Beckmann.
diff --git a/checks/cruft b/checks/cruft
index ee19502..3f9f321 100644
--- a/checks/cruft
+++ b/checks/cruft
@@ -94,11 +94,15 @@ if (-e "debfiles/files" and not -z "debfiles/files") {
# This doens't really belong here, but there isn't a better place at the
# moment to put this check.
+my $version = $info->field('version');
if ($info->native) {
- my $version = $info->field('version');
if ($version =~ /-/ and $version !~ /-0\.[^-]+$/) {
tag 'native-package-with-dash-version';
}
+} else {
+ if ($version !~ /-/) {
+ tag 'non-native-package-with-native-version';
+ }
}
# Check if this is a documentation package that's not arch: all. This doesn't
diff --git a/checks/cruft.desc b/checks/cruft.desc
index 04adec4..4d42a2b 100644
--- a/checks/cruft.desc
+++ b/checks/cruft.desc
@@ -16,6 +16,15 @@ Info: Native packaging should only be used if a piece of software was
the reason is the location of the original source tarball. dpkg-source
searches for this in ../package_upstream-version.orig.tar.gz.
+Tag: non-native-package-with-native-version
+Severity: normal
+Certainty: certain
+Info: This package has a native version number (a version number without a
+ dash and a Debian portion) but is built as a non-native package. Usually
+ this is an error caused by a stray <tt>*.orig.tar.gz</tt> file in the
+ parent directory fooling <tt>dpkg-source</tt> into thinking it was
+ supposed to be a non-native package.
+
Tag: documentation-package-not-architecture-independent
Severity: normal
Certainty: certain
diff --git a/debian/changelog b/debian/changelog
index 4d65a54..004a510 100755
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,7 @@ lintian (2.3.1) UNRELEASED; urgency=low
* Summary of tag changes:
+ Added:
- init.d-script-missing-start
+ - non-native-package-with-native-version
* {checks,collection}/*.desc:
+ [RG] Remove Unpack-Level fields and depend on the 'unpacked'
@@ -14,6 +15,8 @@ lintian (2.3.1) UNRELEASED; urgency=low
* checks/cruft:
+ [RA] Fix the regex to properly ignore CMakeCache.txt in the debian
directory. Thanks, Aaron M. Ucko. (Closes: #553264)
+ + [RA] Check for a non-native package with a native version. Thanks,
+ Andreas Beckmann.
* checks/files.desc:
+ [RG] Add a missing 'it' to the description of duplicate-font-file.
* checks/init.d.desc:
diff --git a/t/tests/cruft-non-native-version/desc b/t/tests/cruft-non-native-version/desc
new file mode 100644
index 0000000..b22416c
--- /dev/null
+++ b/t/tests/cruft-non-native-version/desc
@@ -0,0 +1,6 @@
+Testname: cruft-non-native-version
+Sequence: 6000
+Type: non-native
+Version: 1.0
+Description: Test non-native package with native version
+Test-For: non-native-package-with-native-version
diff --git a/t/tests/cruft-non-native-version/tags b/t/tests/cruft-non-native-version/tags
new file mode 100644
index 0000000..d9b4e84
--- /dev/null
+++ b/t/tests/cruft-non-native-version/tags
@@ -0,0 +1 @@
+W: cruft-non-native-version source: non-native-package-with-native-version
diff --git a/t/tests/basic-non-native-with-epoch/upstream/README b/t/tests/cruft-non-native-version/upstream/README
similarity index 100%
copy from t/tests/basic-non-native-with-epoch/upstream/README
copy to t/tests/cruft-non-native-version/upstream/README
--
Debian package checker
Reply to: