summaryrefslogtreecommitdiff
path: root/guix/gexp.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2020-05-15 15:22:07 +0200
committerLudovic Courtès <ludo@gnu.org>2020-05-15 15:22:07 +0200
commitd2cd4134c1960c76aa70f44d7356bc74494471c7 (patch)
tree43e0bf27ef6b88ce23e23defa0e1d1ad0e2a4e14 /guix/gexp.scm
parent1130e8c8178386cf6d34c4ede7be0f5a9d30ad52 (diff)
downloadguix-patches-d2cd4134c1960c76aa70f44d7356bc74494471c7.tar
guix-patches-d2cd4134c1960c76aa70f44d7356bc74494471c7.tar.gz
gexp: Simplify use of 'with-target' in 'compiled-modules'.
* guix/gexp.scm (compiled-modules)[build]: Simplify 'with-target' handling.
Diffstat (limited to 'guix/gexp.scm')
-rw-r--r--guix/gexp.scm17
1 files changed, 6 insertions, 11 deletions
diff --git a/guix/gexp.scm b/guix/gexp.scm
index 2a4b36519c..62973460f2 100644
--- a/guix/gexp.scm
+++ b/guix/gexp.scm
@@ -1456,17 +1456,12 @@ TARGET, a GNU triplet."
(ungexp (* total 2))
entry)
- (ungexp-splicing
- (if target
- (gexp ((with-target (ungexp target)
- (lambda ()
- (compile-file entry
- #:output-file output
- #:opts
- %auto-compilation-options)))))
- (gexp ((compile-file entry
- #:output-file output
- #:opts %auto-compilation-options)))))
+ (with-target (ungexp (or target (gexp %host-type)))
+ (lambda ()
+ (compile-file entry
+ #:output-file output
+ #:opts
+ %auto-compilation-options)))
(+ 1 processed))))