summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRaphaël Hertzog <hertzog@debian.org>2009-11-22 16:34:11 +0100
committerRaphaël Hertzog <hertzog@debian.org>2009-11-22 16:34:11 +0100
commit7f64bc6544061ba534541a66ae4dab8c88a96a14 (patch)
tree32357ebc378c91db1408c417f059442b27e3623f
parentd3cc0605237b615e294c5060b911bf6b1b883731 (diff)
downloaddpkg-7f64bc6544061ba534541a66ae4dab8c88a96a14.tar.gz
dpkg-source: fail if several orig.tar files are available
This concerns formats 2.0 and 3.0 (quilt) where the upstream tarball can be available with different compression schemes. We need precisely one file otherwise it doesn't know which one should be used and might pick the wrong one.
-rw-r--r--debian/changelog3
-rw-r--r--scripts/Dpkg/Source/Package/V2.pm4
2 files changed, 7 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog
index 1c5195e3e..1ac63e9c8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,9 @@ dpkg (1.15.5.3) UNRELEASED; urgency=low
instead to directly get a pipe file descriptor. Closes: #557013
* Put "3.0 (quilt)" in the default list of formats tried by dpkg-source
after "1.0" and before "3.0 (native)".
+ * Let dpkg-source fail if several upstream orig.tar files are available
+ (using different compression scheme) since we don't know which one
+ to use.
[ Guillem Jover ]
* Verify that the alternative used in update-alternatives --set has been
diff --git a/scripts/Dpkg/Source/Package/V2.pm b/scripts/Dpkg/Source/Package/V2.pm
index e1874cb2d..6757795c3 100644
--- a/scripts/Dpkg/Source/Package/V2.pm
+++ b/scripts/Dpkg/Source/Package/V2.pm
@@ -248,6 +248,10 @@ sub do_build {
my @origtarballs;
foreach (sort $self->find_original_tarballs()) {
if (/\.orig\.tar\.$comp_regex$/) {
+ if (defined($tarfile)) {
+ error(_g("several orig.tar files found (%s and %s) but only " .
+ "one is allowed"), $tarfile, $_);
+ }
$tarfile = $_;
push @origtarballs, $_;
$self->add_file($_);