aboutsummaryrefslogtreecommitdiff
path: root/gnu/system/vm.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2016-09-30 12:01:32 +0200
committerLudovic Courtès <ludo@gnu.org>2016-09-30 12:05:27 +0200
commit79355ae3e84359716f5135cc7083e72246bc8bf9 (patch)
tree6b61851e2153581578bb78ef0f177b8841ee5db7 /gnu/system/vm.scm
parent39d6b9c99f297e14fc4f47f002be3d40556726be (diff)
parent86d8f6d3efb8300a3354735cbf06be6c01e23243 (diff)
downloadguix-79355ae3e84359716f5135cc7083e72246bc8bf9.tar
guix-79355ae3e84359716f5135cc7083e72246bc8bf9.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'gnu/system/vm.scm')
-rw-r--r--gnu/system/vm.scm23
1 files changed, 5 insertions, 18 deletions
diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm
index c31e3a80ef..03f7d6c913 100644
--- a/gnu/system/vm.scm
+++ b/gnu/system/vm.scm
@@ -26,6 +26,7 @@
#:use-module (guix packages)
#:use-module (guix monads)
#:use-module (guix records)
+ #:use-module (guix modules)
#:use-module ((gnu build vm)
#:select (qemu-command))
@@ -90,21 +91,6 @@
(options "trans=virtio")
(check? #f))))
-(define %vm-module-closure
- ;; The closure of (gnu build vm), roughly.
- ;; FIXME: Compute it automatically.
- '((gnu build vm)
- (gnu build install)
- (gnu build linux-boot)
- (gnu build linux-modules)
- (gnu build file-systems)
- (guix elf)
- (guix records)
- (guix build utils)
- (guix build syscalls)
- (guix build bournish)
- (guix build store-copy)))
-
(define* (expression->derivation-in-linux-vm name exp
#:key
(system (%current-system))
@@ -148,7 +134,8 @@ made available under the /xchg CIFS share."
(define builder
;; Code that launches the VM that evaluates EXP.
- (with-imported-modules %vm-module-closure
+ (with-imported-modules (source-module-closure '((guix build utils)
+ (gnu build vm)))
#~(begin
(use-modules (guix build utils)
(gnu build vm))
@@ -205,7 +192,8 @@ register INPUTS in the store database of the image so that Guix can be used in
the image."
(expression->derivation-in-linux-vm
name
- (with-imported-modules %vm-module-closure
+ (with-imported-modules (source-module-closure '((gnu build vm)
+ (guix build utils)))
#~(begin
(use-modules (gnu build vm)
(guix build utils))
@@ -462,7 +450,6 @@ with '-virtfs' options for the host file systems listed in SHARED-FS."
"")
" -no-reboot -net nic,model=virtio \
" #$@(map virtfs-option shared-fs) " \
- -net user \
-vga std \
-drive file=" #$image
",if=virtio,cache=writeback,werror=report,readonly \