linux-initrd: Rename 'qemu-initrd' to 'base-initrd'.

* gnu/system/linux-initrd.scm (qemu-initrd): Rename to...
  (base-initrd): ... this.
* gnu/system.scm (<operating-system>)[initrd]: Update accordingly.
* gnu/system/vm.scm (expression->derivation-in-linux-vm,
  system-disk-image, virtualized-operating-system): Likewise.
This commit is contained in:
Ludovic Courtès 2014-06-30 20:56:45 +02:00
parent 4fc96187b9
commit 060238ae64
3 changed files with 10 additions and 11 deletions

View File

@ -83,7 +83,7 @@
(bootloader operating-system-bootloader) ; <grub-configuration> (bootloader operating-system-bootloader) ; <grub-configuration>
(initrd operating-system-initrd ; (list fs) -> M derivation (initrd operating-system-initrd ; (list fs) -> M derivation
(default qemu-initrd)) (default base-initrd))
(host-name operating-system-host-name) ; string (host-name operating-system-host-name) ; string

View File

@ -35,7 +35,7 @@
#:use-module (ice-9 regex) #:use-module (ice-9 regex)
#:use-module (srfi srfi-1) #:use-module (srfi srfi-1)
#:export (expression->initrd #:export (expression->initrd
qemu-initrd)) base-initrd))
;;; Commentary: ;;; Commentary:
@ -201,16 +201,15 @@ initrd code."
(($ <file-system> device title mount-point type flags options _ check?) (($ <file-system> device title mount-point type flags options _ check?)
(list device title mount-point type flags options check?)))) (list device title mount-point type flags options check?))))
(define* (qemu-initrd file-systems (define* (base-initrd file-systems
#:key #:key
qemu-networking? qemu-networking?
virtio? virtio?
volatile-root? volatile-root?
guile-modules-in-chroot?) guile-modules-in-chroot?)
"Return a monadic derivation that builds an initrd for use in a QEMU guest "Return a monadic derivation that builds a generic initrd. FILE-SYSTEMS is
where the store is shared with the host. FILE-SYSTEMS is a list of a list of file-systems to be mounted by the initrd, possibly in addition to
file-systems to be mounted by the initrd, possibly in addition to the root the root file system specified on the kernel command line via '--root'.
file system specified on the kernel command line via '--root'.
When QEMU-NETWORKING? is true, set up networking with the standard QEMU When QEMU-NETWORKING? is true, set up networking with the standard QEMU
parameters. When VIRTIO? is true, load additional modules so the initrd can parameters. When VIRTIO? is true, load additional modules so the initrd can
@ -282,7 +281,7 @@ exception and backtrace!)."
#:qemu-guest-networking? #$qemu-networking? #:qemu-guest-networking? #$qemu-networking?
#:guile-modules-in-chroot? '#$guile-modules-in-chroot? #:guile-modules-in-chroot? '#$guile-modules-in-chroot?
#:volatile-root? '#$volatile-root?)) #:volatile-root? '#$volatile-root?))
#:name "qemu-initrd" #:name "base-initrd"
#:modules '((guix build utils) #:modules '((guix build utils)
(guix build linux-initrd)) (guix build linux-initrd))
#:to-copy helper-packages #:to-copy helper-packages

View File

@ -153,7 +153,7 @@ made available under the /xchg CIFS share."
(coreutils -> (car (assoc-ref %final-inputs "coreutils"))) (coreutils -> (car (assoc-ref %final-inputs "coreutils")))
(initrd (if initrd ; use the default initrd? (initrd (if initrd ; use the default initrd?
(return initrd) (return initrd)
(qemu-initrd %linux-vm-file-systems (base-initrd %linux-vm-file-systems
#:virtio? #t #:virtio? #t
#:qemu-networking? #t #:qemu-networking? #t
#:guile-modules-in-chroot? #t)))) #:guile-modules-in-chroot? #t))))
@ -287,7 +287,7 @@ to USB sticks meant to be read-only."
(let ((os (operating-system (inherit os) (let ((os (operating-system (inherit os)
;; Since this is meant to be used on real hardware, don't set up ;; Since this is meant to be used on real hardware, don't set up
;; QEMU networking. ;; QEMU networking.
(initrd (cut qemu-initrd <> (initrd (cut base-initrd <>
#:volatile-root? volatile?)) #:volatile-root? volatile?))
;; Force our own root file system. ;; Force our own root file system.
@ -350,7 +350,7 @@ of the GNU system as described by OS."
"Return an operating system based on OS suitable for use in a virtualized "Return an operating system based on OS suitable for use in a virtualized
environment with the store shared with the host." environment with the store shared with the host."
(operating-system (inherit os) (operating-system (inherit os)
(initrd (cut qemu-initrd <> (initrd (cut base-initrd <>
#:volatile-root? #t #:volatile-root? #t
#:virtio? #t #:virtio? #t
#:qemu-networking? #t)) #:qemu-networking? #t))