The following commit has been merged in the master branch:
commit 1463ac71babf0432b5753c20eebc060363694e34
Author: Raphael Hertzog <[email protected]>
Date: Mon Mar 9 22:21:28 2009 +0100
dpkg-source: drop support of debian/control's Format field
There are no interesting use case where it makes sense to hardcode
the source format directly in debian/control. So drop that feature
before people start abusing this field instead of using
debian/source/format (which dpkg-source can have to create in some cases).
diff --git a/debian/changelog b/debian/changelog
index 7cba73b..662399f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -9,6 +9,9 @@ dpkg (1.15.1) UNRELEASED; urgency=low
* Fix dpkg-shlibdeps so that it works again when analyzing binaries
outside of package's directory. Closes: #518687
* Modify dpkg-shlibdeps to let shlibs.local override symbols files too.
+ * Drop support of debian/control's “Format” field used by dpkg-source while
+ it's not too late. Instead debian/source/format should be used to indicate
+ the desired source package format.
[ Updated dselect translations ]
* German (Sven Joachim).
diff --git a/man/dpkg-source.1 b/man/dpkg-source.1
index abda018..4e954d5 100644
--- a/man/dpkg-source.1
+++ b/man/dpkg-source.1
@@ -57,7 +57,6 @@ additional parameters might be accepted.
\fBdpkg\-source\fP will build the source package with the first format
that works from this ordered list:
-the format indicated in the \fIFormat\fP field of \fBdebian/control\fP,
the format(s) indicated with the \fI\-\-format\fP command-line option(s),
the format indicated in \fBdebian/source/format\fP,
"1.0", "3.0 (native)". See below for an extensive description of
@@ -93,8 +92,7 @@ defaults to the debian standard format.
.TP
.BI \-\-format= value
Try first the given format for building the source package. If used
-multiple times, they are tried in order. It doesn't override
-any explicit \fIFormat\fP field in \fBdebian/control\fP but it does
+multiple times, they are tried in order. It does
override any format given in \fBdebian/source/format\fP.
.TP
.BI \-V name = value
diff --git a/scripts/dpkg-source.pl b/scripts/dpkg-source.pl
index 232922b..0c4b61e 100755
--- a/scripts/dpkg-source.pl
+++ b/scripts/dpkg-source.pl
@@ -164,7 +164,7 @@ if ($options{'opmode'} eq 'build') {
if (m/^Source$/i) {
set_source_package($v);
$fields->{$_} = $v;
- } elsif (m/^(Format|Standards-Version|Origin|Maintainer|Homepage)$/i ||
+ } elsif (m/^(Standards-Version|Origin|Maintainer|Homepage)$/i ||
m/^Dm-Upload-Allowed$/i ||
m/^Vcs-(Browser|Arch|Bzr|Cvs|Darcs|Git|Hg|Mtn|Svn)$/i) {
$fields->{$_} = $v;
@@ -252,9 +252,7 @@ if ($options{'opmode'} eq 'build') {
$fields->{'Binary'} = join(', ', @binarypackages);
# Generate list of formats to try
- my @try_formats;
- push @try_formats, $fields->{'Format'} if exists $fields->{'Format'};
- push @try_formats, @cmdline_formats;
+ my @try_formats = (@cmdline_formats);
if (-e "$dir/debian/source/format") {
open(FORMAT, "<", "$dir/debian/source/format") ||
syserr(_g("cannot read %s"), "$dir/debian/source/format");
--
dpkg's main repository
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]