Fixes a regression in installation tests, whereby 'guix system init'
would report that virtio modules are missing for the target devices.
In practice virtio modules were always available since 'base-initrd' was
always called with #:virtio? #t. This commit simply moves them to
'%base-initrd-modules' so that 'guix system' knows they're available.
Reported by Danny Milosavljevic <dannym@scratchpost.org> at
<https://debbugs.gnu.org/cgi/bugreport.cgi?bug=30629#112>.
* gnu/system/linux-initrd.scm (default-initrd-modules): Add virtio
modules.
(base-initrd): Remove #:virtio? and 'virtio-modules'.
* gnu/system/vm.scm (expression->derivation-in-linux-vm)
(system-qemu-image, virtualized-operating-system): Remove uses of
#:virtio?.
* doc/guix.texi (Initial RAM Disk): Update 'base-initrd' doc.
Fixes a regression introduced in
bc499b113a, whereby the default initrd
used by 'expression->derivation-in-linux-vm' would lack all the usual
modules: virtio, nls_iso8859-1, etc.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Pass
#:linux-modules to 'base-initrd'.
Fixes a bug whereby, for an "iso9660" file system, it would return
'("iso9660" "isofs"), i.e., both the key and the value.
Reported by Danny Milosavljevic <dannym@scratchpost.org>
at <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=30629#115>.
* gnu/system/linux-initrd.scm (lookup-procedure): 'vhash-assoc' returns
a key/value pair; match it.
* guix/scripts/system.scm (check-mapped-devices): Take an OS instead of
a list of <mapped-device>. Pass #:needed-for-boot? and #:initrd-modules
to CHECK.
(check-initrd-modules): New procedure.
(perform-action): Move 'check-mapped-devices' call first. Add call to
'check-initrd-modules'.
* gnu/system/mapped-devices.scm (check-device-initrd-modules): New
procedure.
(check-luks-device): Add #:initrd-modules and #:needed-for-boot?. Use
them to call 'check-device-initrd-modules'.
* gnu/system.scm (<operating-system>)[initrd-modules]: New field.
(operating-system-initrd-file): Pass #:linux-modules to 'make-initrd'.
* gnu/system/linux-initrd.scm (default-initrd-modules): New procedure.
(%base-initrd-modules): New macro.
(base-initrd): Add #:linux-modules and honor it.
* gnu/system/install.scm (embedded-installation-os): Use
'initrd-modules' instead of 'initrd'.
* gnu/tests/install.scm (%raid-root-os): Likewise.
* doc/guix.texi (operating-system Reference): Add 'initrd-modules'.
(Initial RAM Disk): Document it. Adjust example to not use
#:extra-modules.
* gnu/system/locale.scm (localedef-command, single-locale-directory): Use only
the major+minor part of the libc version number in the locale directory name.
* gnu/system/install.scm (embedded-installation-os): New variable.
(beaglebone-black-installation-os): Use it.
(a20-olinuxino-lime2-emmc-installation-os): Use it.
(a20-olinuxino-micro-installation-os): Use it.
(banana-pi-m2-ultra-installation-os): Use it.
* gnu/system/install.scm (agetty-default-service): New variable.
(beaglebone-black-installation-os): Use it.
(a20-olinuxino-lime2-emmc-installation-os): Use it.
(a20-olinuxino-micro-installation-os): Use it.
(banana-pi-m2-ultra-installation-os): Use it.
* gnu/bootloader/u-boot.scm (u-boot-banana-pi-m2-ultra-bootloader): New
exported variable.
(install-allwinner-u-boot): New variable.
(u-boot-allwinner-bootloader): New variable.
* gnu/packages/bootloaders.scm (u-boot-banana-pi-m2-ultra): New exported
variable.
* gnu/system/install.scm (banana-pi-m2-ultra-installation-os): New exported
variable.
Suggested by Danny Milosavljevic <dannym@scratchpost.org>
in <https://bugs.gnu.org/29922>.
* gnu/build/linux-boot.scm (boot-system): Add #:on-error parameter and
pass it to 'call-with-error-handling'.
* gnu/system/linux-initrd.scm (raw-initrd): Add #:on-error and pass it.
(base-initrd): Likewise.
This avoids the hard-coded "/dev/sda1", which only made sense when the
image is run with "qemu-system-x86_64 -hda", not when it's passed to
Xen, etc.
Reported by Andreas Enge <andreas@enge.fr>.
* gnu/system/vm.scm (system-qemu-image): Define 'root-uuid', use it as
the 'device' field for "/", and pass it to 'qemu-image'.
On ARM32 without LPAE support, hugetlb control group is not supported.
As it is not needed by elogind, remove it for all platforms.
* gnu/system/file-systems.scm (%control-groups): Remove hugetlb from control
groups platforms.
This improves the performance of the shared store for operations involving
lots of files, e.g. searching through the store.
* gnu/system/vm.scm (mapping->file-system): Add cache=loose to options.
* gnu/bootloader/extlinux.scm (install-extlinux): Factorize bootloader
writing in a new procedure write-file-on-device defined in (gnu build
bootloader).
* gnu/build/bootloader.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add new file.
* gnu/system/vm.scm (qemu-img): Adapt to import and use (gnu build bootloader)
module during derivation building.
* gnu/scripts/system.scm (bootloader-installer-derivation): Ditto.
* gnu/build/vm.scm (load-in-linux-vm): New argument #:target-arm32.
Use it to adapt command for qemu-system-arm. This implies to choose a
machine ("virt"), use the correct console port "ttyAMA0", disable KVM use
that is buggy on some ARM boards (Odroid XU4 for example) and use user mode
network stack instead of NIC. Gather all those options in a new variable
"arch-specific-flags".
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Pass
to load-in-linux-vm "#:target-arm32?" argument.
This reduces the closure of Guile from 131 MiB to 116 MiB and removes
extra readline/ncurses builds from the bootstrap path.
* gnu/packages/guile.scm (guile-2.0)[inputs]: Remove READLINE.
(make-guile-readline): New procedure.
(guile-readline): New variable.
* gnu/system/shadow.scm (default-skeletons): Adjust '.guile' so that it
gracefully deals with missing (ice-9 readline).
Reported by Christopher Baines <mail@cbaines.net>
at <https://lists.gnu.org/archive/html/guix-devel/2017-12/msg00058.html>.
* gnu/services/ssh.scm (<openssh-configuration>)[%auto-start?]: New
field.
(openssh-shepherd-service): Honor it.
* gnu/system/install.scm (%installation-services): Set '%auto-start?' to
#f for openssh-service-type.