summaryrefslogtreecommitdiff
path: root/gnu/build
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2020-05-27 23:04:48 +0200
committerLudovic Courtès <ludo@gnu.org>2020-06-06 23:28:49 +0200
commitb3477234455a555917365b6b4961004e2361c57f (patch)
tree59b2ebb6b12d5b413a6fc8c3380de31c80252924 /gnu/build
parent0c053a3973fbd8a62961998ca1b75152e8741229 (diff)
downloadguix-patches-b3477234455a555917365b6b4961004e2361c57f.tar
guix-patches-b3477234455a555917365b6b4961004e2361c57f.tar.gz
vm: 'expression->derivation-in-linux-vm' always returns a native build.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Remove #:target. [builder]: Use #+. Don't pass #:target-arm32? and #:target-aarch64? to 'load-in-linux-vm'. Pass #:target #f to 'gexp->derivation'. (qemu-image): Adjust accordingly. * gnu/build/vm.scm (load-in-linux-vm): Remove #:target-aarch64? and #:target-arm32?. Define them as local variables.
Diffstat (limited to 'gnu/build')
-rw-r--r--gnu/build/vm.scm11
1 files changed, 8 insertions, 3 deletions
diff --git a/gnu/build/vm.scm b/gnu/build/vm.scm
index 433b5a7e8d..0f0ceae18f 100644
--- a/gnu/build/vm.scm
+++ b/gnu/build/vm.scm
@@ -84,8 +84,6 @@
linux initrd
make-disk-image?
single-file-output?
- target-arm32?
- target-aarch64?
(disk-image-size (* 100 (expt 2 20)))
(disk-image-format "qcow2")
(references-graphs '()))
@@ -101,7 +99,14 @@ access it via /dev/hda.
REFERENCES-GRAPHS can specify a list of reference-graph files as produced by
the #:references-graphs parameter of 'derivation'."
- (define target-arm? (or target-arm32? target-aarch64?))
+ (define target-arm32?
+ (string-prefix? "arm-" %host-type))
+
+ (define target-aarch64?
+ (string-prefix? "aarch64-" %host-type))
+
+ (define target-arm?
+ (or target-arm32? target-aarch64?))
(define arch-specific-flags
`(;; On ARM, a machine has to be specified. Use "virt" machine to avoid