[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#72335: marked as done ([WITHDRAWN] Optional build-arch and build-indep targets for debian/rules)



Your message dated Mon, 30 Oct 2000 23:44:18 +0200
with message-id <20001030234418.C19892@gaia.iki.fi>
and subject line Bug#72335: [PROPOSED] Optional build-arch and build-indep targets for debian/rules
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Darren Benham
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 24 Sep 2000 14:27:28 +0000
>From ajk@gaia.iki.fi Sun Sep 24 09:27:28 2000
Return-path: <ajk@gaia.iki.fi>
Received: from kukkaruukku.keltti.jyu.fi [::ffff:130.234.184.31] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 13dCka-0006o6-00; Sun, 24 Sep 2000 09:27:28 -0500
Received: from ajk by kukkaruukku.keltti.jyu.fi with local (Exim 3.16 #1 (Debian))
	id 13dCkv-0007xL-00
	for <submit@bugs.debian.org>; Sun, 24 Sep 2000 17:27:49 +0300
Date: Sun, 24 Sep 2000 17:27:49 +0300
From: Antti-Juhani Kaijanaho <gaia@iki.fi>
To: submit@bugs.debian.org
Subject: [PROPOSED] Optional build-arch and build-indep targets for debian/rules
Message-ID: <20000924172748.D3236@gaia.iki.fi>
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="k1lZvvs/B4yU6o8G"
Content-Disposition: inline
User-Agent: Mutt/1.2.5i
Sender: Antti-Juhani Kaijanaho <ajk@gaia.iki.fi>
Delivered-To: submit@bugs.debian.org


--k1lZvvs/B4yU6o8G
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Package: debian-policy
Version: 3.2.1.0
Severity: wishlist

There is a problem with the current build-time dependency system.

The build-time dependency system separates between dependencies needed to
build architecture dependent and architecture independent packages via the
Build-Depends and Build-Depends-Indep fields in debian/control.  However,
since all compilation of the package must happen in the build target of
debian/rules (Packaging Manual section 3.2.1), and since Build-Depends
applies to the build target (Packaging Manual section 8.7), it means that
very rarely can Build-Depends-Indep used, and also that build daemons
building only architecture-dependent parts of the package need often
install also everything needed to build the architecture-independent
parts.  This is not good.

Therefore, I propose two new optional targets in debian/rules.  They would
be named build-arch and build-indep, mirroring the already existing
binary-arch and binary-indep targets.  When they exist, the build target
would have to depend on them; if they don't exist, the build target must
do what they would do.

Additionally, the semantics of the build-time dependency fields would be
changed so that Build-Depends-Indep would apply to the build, build-indep,
binary and binary-indep targets, and Build-Depends would apply to
the build, build-arch, binary and binary-arch targets.  Thus when
a builder wants to build only arch-dependant parts of the package,
she can invoke first the build-arch target (as non-root, if wanted)
and then the binary-arch target (as root).  Then only Build-Depends
packages would need to be installed, fixing the problem.

The reason that the targets be optional is to not make this proposal cause
a major version number increment in policy if the proposal is accepted.
Since the targets are optional, only those packages suffering from
the problem outlined above will want to change, and no packages need
to change.

This proposal requires no code changes anywhere.  However, to make use
of the proposal's improvements to the build system, dpkg-buildpackage
and the build daemons will need to be changed to detect and use the new
targets.  I will provide a patch for dpkg-buildpackage, if necessary.

This proposal affects only the packaging manual.  A diff of the SGML
source is attached.

I'm mainly looking for comments and criticism, but seconds are also
appreciated.

-- 
%%% Antti-Juhani Kaijanaho % gaia@iki.fi % http://www.iki.fi/gaia/ %%%

--k1lZvvs/B4yU6o8G
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename=diff

--- packaging.sgml.orig	Sun Sep 24 16:42:17 2000
+++ packaging.sgml	Sun Sep 24 17:16:29 2000
@@ -948,10 +948,11 @@
 	  <p>	    
 	    The targets which are required to be present are:	    
 	    <taglist>
-	      <tag><tt>build</tt></tag>
+	      <tag><tt>build</tt>, <tt>build-arch</tt> (optional),
+                <tt>build-indep</tt> (optional)</tag>
 	      <item>
 		<p>
-		  This should perform all non-interactive
+		  The <tt>build</tt> target should perform all non-interactive
 		  configuration and compilation of the package.  If a
 		  package has an interactive pre-build configuration
 		  routine, the Debianised source package should be
@@ -959,6 +960,37 @@
 		  built without rerunning the configuration.
 		</p>
 
+                <p>
+                  A package may provide one or both of the targets
+                  <tt>build-arch</tt> and <tt>build-indep</tt>.  The
+                  <tt>build-arch</tt> target, if provided, should
+                  perform all non-interactive configuration and
+                  compilation required for producing all
+                  architecture-dependant binary packages (those
+                  packages for which the body of the
+                  <tt>Architecture</tt> field in
+                  <tt>debian/control</tt> is not <tt>all</tt>).
+                  Similarly, the <tt>build-indep</tt> target, if
+                  provided, should perform all non-interactive
+                  configuration and compilation required for producing
+                  all architecture-independent binary packages (those
+                  packages for which the body of the
+                  <tt>Architecture</tt> field in
+                  <tt>debian/control</tt> is <tt>all</tt>).  The
+                  <tt>build</tt> target should depend on those of the
+                  targets <tt>build-arch</tt> and <tt>build-indep</tt>
+                  that are provided in the rules file.
+                </p>
+
+                <p>
+                  If one or both of the targets <tt>build-arch</tt>
+                  and <tt>build-indep</tt> are not provided, then
+                  invoking <tt>debian/rules</tt> with one of the
+                  not-provided targets as arguments should produce a
+                  exit status code of 2.  Usually this is provided
+                  automatically by make if the target is missing.
+                </p>
+
 		<p>		  
 		  For some packages, notably ones where the same
 		  source tree is compiled in different ways to produce
@@ -973,9 +1005,11 @@
 		  binary package out of each.
 		</p>
 
-		<p>		  
-		  The <prgn>build</prgn> target must not do anything
-		  that might require root privilege.
+		<p>
+                  The targets <prgn>build</prgn>,
+		  <prgn>build-arch</prgn> and <prgn>build-indep</prgn>
+		  target must not do anything that might require root
+		  privilege.
 		</p>
 
 		<p>		  
@@ -1017,15 +1051,16 @@
 		  <prgn>binary-indep</prgn>.
 		</p>
 
-		<p>		  
-		  Both <prgn>binary-*</prgn> targets should depend on
-		  the <prgn>build</prgn> target, above, so that the
-		  package is built if it has not been already.  It
-		  should then create the relevant binary package(s),
-		  using <prgn>dpkg-gencontrol</prgn> to make their
-		  control files and <prgn>dpkg-deb</prgn> to build
-		  them and place them in the parent of the top level
-		  directory.
+		<p> Both <prgn>binary-*</prgn> targets should depend
+		  on the <prgn>build</prgn> target, or on the
+		  appropriate <prgn>build-arch</prgn>
+		  <prgn>build-indep</prgn> target, if provided, above,
+		  so that the package is built if it has not been
+		  already.  It should then create the relevant binary
+		  package(s), using <prgn>dpkg-gencontrol</prgn> to
+		  make their control files and <prgn>dpkg-deb</prgn>
+		  to build them and place them in the parent of the
+		  top level directory.
 		</p>
 
 		<p>		  
@@ -4201,8 +4236,8 @@
 	      <p>
                 The <tt>Build-Depends</tt> and
 		<tt>Build-Conflicts</tt> fields apply to the targets
-		<tt>build</tt>, <tt>binary</tt>, <tt>binary-arch</tt>
-		and <tt>binary-indep</tt>.
+		<tt>build</tt>, <tt>build-arch</tt>, <tt>binary</tt>,
+		<tt>binary-arch</tt> and <tt>binary-indep</tt>.
 	      </p>
 	    </item>
 	    <tag><tt>Build-Depends-Indep</tt>, <tt>Build-Conflicts-Indep</tt></tag>
@@ -4210,7 +4245,8 @@
 	      <p>
                 The <tt>Build-Depends-Indep</tt> and
 		<tt>Build-Conflicts-Indep</tt> fields apply to the
-		targets <tt>binary</tt> and <tt>binary-indep</tt>.
+		targets <tt>build</tt>, <tt>build-indep</tt>,
+		<tt>binary</tt> and <tt>binary-indep</tt>.
 	      </p>
 	    </item>
 	  </taglist>

--k1lZvvs/B4yU6o8G--

---------------------------------------
Received: (at 72335-done) by bugs.debian.org; 30 Oct 2000 21:44:09 +0000
>From ajk@gaia.iki.fi Mon Oct 30 15:44:09 2000
Return-path: <ajk@gaia.iki.fi>
Received: from kukkaruukku.keltti.jyu.fi [::ffff:130.234.184.31] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 13qMiv-00059V-00; Mon, 30 Oct 2000 15:44:09 -0600
Received: from south.invalid ([192.168.0.3] ident=mail)
	by kukkaruukku.keltti.jyu.fi with esmtp (Exim 3.12 #1 (Debian))
	id 13qMjO-0008HP-00; Mon, 30 Oct 2000 23:44:38 +0200
Received: from ajk by south.invalid with local (Exim 3.16 #1 (Debian))
	id 13qMj5-0005iA-00; Mon, 30 Oct 2000 23:44:19 +0200
Date: Mon, 30 Oct 2000 23:44:18 +0200
From: Antti-Juhani Kaijanaho <gaia@iki.fi>
To: submit@bugs.debian.org
Cc: 72335-done@bugs.debian.org
Subject: Re: Bug#72335: [PROPOSED] Optional build-arch and build-indep targets for debian/rules
Message-ID: <20001030234418.C19892@gaia.iki.fi>
References: <20000924172748.D3236@gaia.iki.fi>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.2.5i
In-Reply-To: <20000924172748.D3236@gaia.iki.fi>; from gaia@iki.fi on Sun, Sep 24, 2000 at 05:27:49PM +0300
Sender: Antti-Juhani Kaijanaho <ajk@gaia.iki.fi>
Delivered-To: 72335-done@bugs.debian.org

retitle 72335 [WITHDRAWN] Optional build-arch and build-indep targets for debian/rules
thanks

Due to lack of interest, I am withdrawing this proposal.



Reply to: