guix-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 6/7] guix build: Add 'build-package'.


From: Alex Kost
Subject: Re: [PATCH 6/7] guix build: Add 'build-package'.
Date: Fri, 18 Sep 2015 21:51:36 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Ludovic Courtès (2015-09-08 23:10 +0300) wrote:

> Alex Kost <address@hidden> skribis:
[...]
>> From 9ffc27f7a076e4213ef3bee00e5cebad501685ac Mon Sep 17 00:00:00 2001
>> From: Alex Kost <address@hidden>
>> Date: Thu, 23 Jul 2015 16:16:41 +0300
>> Subject: [PATCH 2/2] guix build: Add 'build-package'.
>> MIME-Version: 1.0
>> Content-Type: text/plain; charset=UTF-8
>> Content-Transfer-Encoding: 8bit
>>
>> * guix/scripts/system.scm (maybe-build): Move to ...
>> * guix/scripts/build.scm: ...here.
>>   (build-package): New procedure.
>
> [...]
>
>> +(define* (build-package package
>> +                        #:key (use-substitutes? #t) (dry-run? #f)
>> +                        #:allow-other-keys
>> +                        #:rest build-options)
>> +  "Build PACKAGE using BUILD-OPTIONS.
>> +Show what and how will/would be built."
>> +  (with-store store
>> +    (run-with-store store
>> +      (mbegin %store-monad
>> +        (apply set-build-options*
>
> Please remove ‘with-store’ and ‘run-with-store’.  This should be done on
> the Emacs side (maybe via the ,run-in-store meta-command?).

Sure, ",run-in-store" sounds great.  I have pushed the patches for
adding (guix scripts), 'set-build-options*' and
'show-derivation-outputs', so the attached patch (for adding
'build-package') is applied cleanly to master.

Ludovic Courtès (2015-08-28 12:24 +0300) wrote:

> Alex Kost <address@hidden> skribis:
>
>> Ludovic Courtès (2015-08-26 14:12 +0300) wrote:
>>
>>> Maybe ‘build-package’ could go to (guix packages)?
>>
>> ‘build-package’ uses ‘show-…’ procedures from (guix ui) module.  I
>> thought that adding this module to (guix packages) was not desired, or
>> is it OK?
>
> Right, sorry.  So maybe leave in (guix build scripts) with a comment
> explaining that it doesn’t have a better place and is for use by the
> Emacs UI.  (Make sure to use the monadic style as suggested in a
> previous message.)

So I suppose this comment is not needed anymore (right?) as
'build-package' will beplaced in (guix scripts), and it looks like a
rather general procedure.  For example, it may be used for something
like ‘guix build --package-from-file’ suggested by David:
<http://lists.gnu.org/archive/html/guix-devel/2015-08/msg00107.html>.

Attachment: 0001-scripts-Add-build-package.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]