From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Build system phases Date: Mon, 12 Jan 2015 10:31:22 +0100 Message-ID: <87k30swdjp.fsf_-_@gnu.org> References: <20150111151247.GA23839@debian> <20150111152509.GA23932@debian> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45170) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YAbLP-0007qi-0n for guix-devel@gnu.org; Mon, 12 Jan 2015 04:31:34 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YAbLI-0003oW-60 for guix-devel@gnu.org; Mon, 12 Jan 2015 04:31:30 -0500 Received: from hera.aquilenet.fr ([2a01:474::1]:36503) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YAbLI-0003oF-0G for guix-devel@gnu.org; Mon, 12 Jan 2015 04:31:24 -0500 In-Reply-To: <20150111152509.GA23932@debian> (Andreas Enge's message of "Sun, 11 Jan 2015 16:25:09 +0100") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Andreas Enge Cc: guix-devel@gnu.org Andreas Enge skribis: > I also wonder if we should not modify the structure of our build system c= ode. > Our different build systems end up calling gnu:gnu-build with a list of > phases. That=E2=80=99s intended. =E2=80=9CPhases=E2=80=9D are a build-side entity,= and so they get composed on the build side, for instance by reusing =E2=80=98gnu-build=E2= =80=99 or =E2=80=98%standard-phases=E2=80=99. > Could this not be done all the time? And then a build system be defined as > a list of phases? For instance, trivial-build-system could be the empty > list, or better yet, the list containing 'unpack. > > Then we could always take the #:phases argument of a package and modify it > by adding a phase, for instance; this would be easier than taking a #:bui= ld > argument and modify it, I think. Initially the idea was to leave phases as an =E2=80=9Cimplementation detail= =E2=80=9D of the build system, something that happens on the build side. There are two questions, I think: 1. Could we move phases to the host side=E2=80=93i.e., somehow make them first-class objects that could be more easily manipulated? 2. Should phases be an integral part of all build systems? There may be something to do with #1. It=E2=80=99s tricky because it has t= o be done in a way that does not increase the amount of computation done when loading package modules, and that does not significantly increase memory requirements either. I=E2=80=99m not sure about #2. Thoughts? Ludo=E2=80=99.