From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: Re: Debugging Guix packages? Date: Tue, 19 Jan 2016 15:52:00 +0100 Message-ID: References: <20160119024256.GA21542@novena-choice-citizen.lan> 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]:41230) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLXdk-0002Ew-JE for guix-devel@gnu.org; Tue, 19 Jan 2016 09:52:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aLXdh-00082A-8C for guix-devel@gnu.org; Tue, 19 Jan 2016 09:52:12 -0500 Received: from venus.bbbm.mdc-berlin.de ([141.80.25.30]:41933) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLXdg-000820-VA for guix-devel@gnu.org; Tue, 19 Jan 2016 09:52:09 -0500 In-Reply-To: <20160119024256.GA21542@novena-choice-citizen.lan> 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: Jookia <166291@gmail.com> Cc: guix-devel@gnu.org Jookia <166291@gmail.com> writes: > It'd be a nice feature to have where I could step through the build pro= cess in > an environment close to the actual build and run build commands myself = like > 'patch' or 'make' or 'configure', but builders can also include Guile c= ode. We already have =E2=80=9Cguix environment --{pure,container} pkg=E2=80=9D= which spawns a shell where all declared inputs are available and all environment variables are set, but it does lack a method to run build phases. It would be very nice if we had a tool to selectively run build phases as defined in the arguments field. > Debugging the builder using Guile seems to be somewhat useful but I hav= en't > figured out how to do that as I'm not versed in Guile and this may not = be the > right level of abstraction. I have been packaging many applications for Guix and have only felt the need for something more advanced than =E2=80=9Cguix environment=E2=80=9D = when building really large stuff like the icedtea or GCC packages. These packages also have complicated build phases that patch the sources and set additional environment variables, and it would have been helpful to have a tool to run selected build phases in the current directory. > I apologize if my thoughts aren't clear, currently it's annoying to hav= e to > decipher packages to hope I'm following along with the build. The alter= native is > to iterate through full builds hoping I get the right output or manuall= y failing > after a certain phase (I'm not sure how to do this.) You can make packages fail by adding a failing build phase. To fail after =E2=80=9Cconfigure=E2=80=9D, for example, you could do something li= ke this: (arguments `(modify-phases %standard-phases (add-after 'configure 'bleh (const #f)))) ~~ Ricardo