summary refs log tree commit diff
path: root/guix/gexp.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2021-03-24 22:42:00 +0100
committerLudovic Courtès <ludo@gnu.org>2021-03-29 16:47:23 +0200
commit19c6ea9ca4d66e7c7c979a17ad92779ea44c5e9e (patch)
treee54335278edc69210666bc37eff38cd6f1af1572 /guix/gexp.scm
parent58210fbea2dbc66ee0947eba7d5def2e593797a4 (diff)
downloadguix-19c6ea9ca4d66e7c7c979a17ad92779ea44c5e9e.tar.gz
gexp: 'gexp->script' uses #:guile also as the guile-for-build.
Previously 'gexp->script' would unconditionally use the
default #:guile-for-build value of 'gexp->derivation'.

* guix/gexp.scm (gexp->script): Pass #:guile to 'load-path-expression'.
Pass #:guile-for-build to 'gexp->derivation'.
Diffstat (limited to 'guix/gexp.scm')
-rw-r--r--guix/gexp.scm6
1 files changed, 5 insertions, 1 deletions
diff --git a/guix/gexp.scm b/guix/gexp.scm
index 654ac0f4d7..afb935761e 100644
--- a/guix/gexp.scm
+++ b/guix/gexp.scm
@@ -1800,10 +1800,13 @@ imported modules in its search path.  Look up EXP's modules in MODULE-PATH."
                        (set-load-path
                         (load-path-expression (gexp-modules exp)
                                               module-path
+                                              #:guile guile
                                               #:extensions
                                               (gexp-extensions exp)
                                               #:system system
-                                              #:target target)))
+                                              #:target target))
+                       (guile-for-build
+                        (lower-object guile system #:target #f)))
     (gexp->derivation name
                       (gexp
                        (call-with-output-file (ungexp output)
@@ -1826,6 +1829,7 @@ imported modules in its search path.  Look up EXP's modules in MODULE-PATH."
                       #:system system
                       #:target target
                       #:module-path module-path
+                      #:guile-for-build guile-for-build
 
                       ;; These derivations are not worth offloading or
                       ;; substituting.