Package: debian-policy Version: 3.9.1.0 Severity: normal Patch attached.
-- System Information: Debian Release: 6.0 APT prefers stable APT policy: (500, 'stable') Architecture: i386 (i686) Kernel: Linux 2.6.32.27-kvm-i386-20110114 (SMP w/1 CPU core) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash debian-policy depends on no packages. debian-policy recommends no packages. Versions of packages debian-policy suggests: ii doc-base 0.9.5 utilities to manage online documen -- no debconf information
>From d0737d445da8bc5e860400a73d6990f542e5ac47 Mon Sep 17 00:00:00 2001 From: Roger Leigh <rle...@debian.org> Date: Wed, 23 Feb 2011 15:14:56 +0000 Subject: [PATCH] Document restrictions on alternative build dependencies The Debian autobuilders only make use of the first alternative in a set of alternatives, in order to guarantee consistent, reproducible builds. This does not include architecture restrictions, because architecture reduction takes place before alternative removal. Alternatives are therefore allowed, and hence useful for backports and other distributions, but are not used by default. --- policy.sgml | 22 ++++++++++++++++++++++ 1 files changed, 22 insertions(+), 0 deletions(-) diff --git a/policy.sgml b/policy.sgml index 642f672..4b87261 100644 --- a/policy.sgml +++ b/policy.sgml @@ -4586,6 +4586,28 @@ Build-Depends: foo [linux-any], bar [any-i386], baz [!linux-any] source package section of the control file (which is the first section). </p> + + <p> + Also note that while <tt>Build-Depends</tt> + and <tt>Build-Depends-Indep</tt> permit the use of + alternative dependencies, these are not normally used by the + Debian autobuilders. A key criterion for building binary + packages for inclusion in the main Debian archive is that + the build must be consistently reproducible, for example + using the same toolchain, and linking against the same + libraries. Alternative dependencies introduce inconsistency + because the set of packages which will be used for the build + can vary. To avoid this, the autobuilders will use only the + first alternative, and will ignore all other alternatives. + This does not include architecture restrictions, which are + reduced to just those needed by the build architecture prior + to alternative removal. Alternatives may therefore be used + to allow building the same package in different + distributions, for example unstable, stable, backports and + experimental, but the first dependency is the one which will + be used to build for the distribution set + in <file>debian/changelog</file>. + </p> </sect> <sect id="binarydeps"> -- 1.7.2.3