From: Russ Allbery Date: Sat, 12 Jun 2010 19:25:02 +0000 (-0700) Subject: Clarify the wording about which build dependencies must be satisfied X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=85567282a323b367a3b96619ce4250651d870038;p=debian%2Fdebian-policy.git Clarify the wording about which build dependencies must be satisfied * Clarify the wording around which build dependencies must be satisfied for different debian/rules targets and add a footnote to the description of the build-arch and build-indep targets explaining why this split does not currently work as desired. (Closes: #328951) --- diff --git a/debian/changelog b/debian/changelog index 7de407a..221e9d6 100644 --- a/debian/changelog +++ b/debian/changelog @@ -94,6 +94,10 @@ debian-policy (3.8.5.0) UNRELEASED; urgency=low Kleine-König. (Closes: #572253) * Explicitly state that packages may remove unmodified, obsolete configuration files during upgrade. (Closes: #470633) + * Clarify the wording around which build dependencies must be satisfied + for different debian/rules targets and add a footnote to the + description of the build-arch and build-indep targets explaining why + this split does not currently work as desired. (Closes: #328951) -- Bill Allombert Mon, 31 May 2010 20:00:28 +0200 diff --git a/policy.sgml b/policy.sgml index f0ba54e..720150d 100644 --- a/policy.sgml +++ b/policy.sgml @@ -1854,21 +1854,28 @@ A package may also provide both of the targets build-arch and build-indep. The build-arch target, if provided, should - perform all the configuration and compilation required - for producing all architecture-dependant binary packages + perform all the configuration and compilation required for + producing all architecture-dependant binary packages (those packages for which the body of the - Architecture field in debian/control - is not all). - Similarly, the build-indep target, if - provided, should perform all the configuration and - compilation required for producing all - architecture-independent binary packages - (those packages for which the body of the - Architecture field in debian/control - is all). + Architecture field in debian/control is + not all). Similarly, the build-indep + target, if provided, should perform all the configuration + and compilation required for producing all + architecture-independent binary packages (those packages + for which the body of the Architecture field + in debian/control is all). The build target should depend on those of the targets build-arch and build-indep that - are provided in the rules file. + are provided in the rules file. + The intent of this split is so that binary-only builds + need not install the dependencies required for + the build-indep target. However, this is not + yet used in practice since dpkg-buildpackage + -B, and therefore the autobuilders, + invoke build rather than build-arch + due to the difficulties in determining whether the + optional build-arch target exists. +

@@ -4847,58 +4854,44 @@ Replaces: mail-transport-agent The dependencies and conflicts they define must be satisfied (as defined earlier for binary packages) in order to invoke the targets in debian/rules, as follows: -

- If you make "build-arch" or "binary-arch", you need - Build-Depends. If you make "build-indep" or - "binary-indep", you need Build-Depends and - Build-Depends-Indep. If you make "build" or "binary", - you need both. -

There is no Build-Depends-Arch; this role is essentially - met with Build-Depends. Anyone building the - build-indep and binary-indep targets - is basically assumed to be building the whole package - anyway and so installs all build dependencies. The - autobuilders use dpkg-buildpackage -B, which - calls build (not build-arch, since it - does not yet know how to check for its existence) and - binary-arch. + met with Build-Depends. Anyone building the + build-indep and binary-indep targets is + assumed to be building the whole package, and therefore + installation of all build dependencies is required.

- The purpose of the original split, I recall, was so that - the autobuilders wouldn't need to install extra packages - needed only for the binary-indep targets. But without a - build-arch/build-indep split, this didn't work, since - most of the work is done in the build target, not in the - binary target. + The autobuilders use dpkg-buildpackage -B, which + calls build, not build-arch since it does + not yet know how to check for its existence, and + binary-arch. The purpose of the original split + between Build-Depends and + Build-Depends-Indep was so that the autobuilders + wouldn't need to install extra packages needed only for the + binary-indep targets. But without a build-arch/build-indep + split, this didn't work, since most of the work is done in + the build target, not in the binary target.

- - Build-Depends, Build-Conflicts + clean, build-arch, and + binary-arch - The Build-Depends and - Build-Conflicts fields must be satisfied when - any of the following targets is invoked: - build, clean, binary, - binary-arch, build-arch, - build-indep and binary-indep. + Only the Build-Depends and Build-Conflicts + fields must be satisfied when these targets are invoked. - Build-Depends-Indep, - Build-Conflicts-Indep + build, build-indep, binary, + and binary-indep - The Build-Depends-Indep and - Build-Conflicts-Indep fields must be - satisfied when any of the following targets is - invoked: build, build-indep, - binary and binary-indep. + The Build-Depends, Build-Conflicts, + Build-Depends-Indep, and + Build-Conflicts-Indep fields must be satisfied when + these targets are invoked.

- -