gexp: computed-file: Honor %guile-for-build.

* guix/gexp.scm (computed-file-compiler): Honor %guile-for-build.
This commit is contained in:
Maxim Cournoyer 2023-02-02 13:09:04 -05:00
parent 5c099f496f
commit 68775338a5
No known key found for this signature in database
GPG key ID: 1260E46482E63562

View file

@ -584,7 +584,8 @@ (define-record-type <computed-file>
(options computed-file-options)) ;list of arguments
(define* (computed-file name gexp
#:key guile (local-build? #t) (options '()))
#:key guile
(local-build? #t) (options '()))
"Return an object representing the store item NAME, a file or directory
computed by GEXP. When LOCAL-BUILD? is #t (the default), it ensures the
corresponding derivation is built locally. OPTIONS may be used to pass
@ -600,7 +601,8 @@ (define-gexp-compiler (computed-file-compiler (file <computed-file>)
;; gexp.
(match file
(($ <computed-file> name gexp guile options)
(mlet %store-monad ((guile (lower-object (or guile (default-guile))
(mlet %store-monad ((guile (lower-object (or guile (%guile-for-build)
(default-guile))
system #:target #f)))
(apply gexp->derivation name gexp #:guile-for-build guile
#:system system #:target target options)))))