Fixes a regression introduced in
commit 075681d350.
* gnu/system.scm (read-boot-parameters): For 'root-device', use
'device-sexp->device', not 'device->sexp'.
* gnu/system.scm (read-boot-parameters)[device->sexp]: New procedure.
Use it for 'root-device' and 'store-device'.
(device->sexp): Serialize the UUID type in addition to its bytevector.
Conceptually a UUID is just a bytevector. However, there's software out
there such as GRUB that relies on the string representation of different
UUID types (e.g., the string representation of DCE UUIDs differs from
that of ISO-9660 UUIDs, even if they are actually bytevectors of the
same length). This new <uuid> record type allows us to preserve
information about the type of UUID so we can eventually convert it to a
string using the right representation.
* gnu/system/uuid.scm (<uuid>): New record type.
(bytevector->uuid): New procedure.
(uuid): Return calls to 'make-uuid'.
(uuid->string): Rewrite using 'match-lambda*' to accept a single 'uuid?'
argument.
* gnu/bootloader/grub.scm (grub-root-search): Check for 'uuid?' instead
of 'bytevector?'.
* gnu/system.scm (bootable-kernel-arguments): Check whether ROOT-DEVICE
is 'uuid?'.
(read-boot-parameters): Use 'bytevector->uuid' when the
store device is a bytevector.
(read-boot-parameters-file): Check for 'uuid?' instead of 'bytevector?'.
(device->sexp): New procedure.
(operating-system-boot-parameters-file): Use it for 'root-device' and
'store'.
(operating-system-bootcfg): Remove conditional in definition of
'root-device'.
* gnu/system/file-systems.scm (file-system->spec): Check for 'uuid?' on
DEVICE and take its bytevector.
* gnu/system/mapped-devices.scm (open-luks-device): Likewise.
* gnu/system/vm.scm (iso9660-image): Call 'uuid-bytevector' for the
#:volume-uuid argument.
* gnu/bootloader.scm (menu-entry-device-mount-point): New variable. Export it.
(<menu-entry>: New field "device".
* gnu/bootloader/grub.scm (grub-confgiuration-file): Handle <menu-entry>
entries.
* gnu/bootloader/extlinux.scm (extlinux-configuration-file): Handle
<menu-entry> entries.
* gnu/system.scm (menu->entry->boot-parameters): Delete variable.
(boot-parameters->menu-entry): New variable. Export it.
(operating-system-bootcfg): Make OLD-ENTRIES a list of <menu-entry>.
* guix/script/system.scm (reinstall-bootloader): Fix bootcfg usage.
(perform-action): Fix bootcfg usage.
* gnu/packages/linux.scm (linux-libre)[arguments]: Add to the regex to
find and install the aarch64-linux kernel.
* gnu/system.scm (system-linux-image-file-name): Add entry for aarch64.
* gnu/system/locale.scm (single-locale-directory): Use 'computed-file'
instead of 'gexp->derivation'.
(locale-directory): Adjust accordingly and do the same.
* gnu/system.scm (operating-system-directory-base-entries): Adjust
accordingly.
* gnu/bootloader.scm (<menu-entry>): New variable. Export associated getters,
This record is extracted from grub module.
* gnu/bootloader/extlinux.scm (extlinux-configuration-file): Use
menu-entry->boot-parameters to convert menu-entry records to
boot-parameters.
* gnu/bootloader/grub.scm (<menu-entry>): Remove.
(boot-parameters->menu-entry): Remove.
(grub-configuration-file): Use boot-parameters to create configuration
entries.
* gnu/system.scm (menu-entry->boot-parameters): New exported procedure.
* gnu/bootloader.scm: New file.
* gnu/bootloader/extlinux.scm: New file.
* gnu/bootloader/grub.scm: New file.
* gnu/local.mk: Build new files.
* gnu/system.scm: Adapt to new bootloader api.
* gnu/scripts/system.scm: Adapt to new bootloader api.
* gnu.scm: Remove (gnu system grub) and replace by (gnu bootloader) and (gnu
bootloader grub) modules.
* gnu/system/grub.scm: Moved content to gnu/bootloader/grub.scm.
* gnu/system/vm: Replace (gnu system grub) module by (gnu bootloader).
* gnu/tests.scm: Ditto.
* gnu/tests/nfs.scm: Ditto.
Followup to 8e815c5b69.
* gnu/system.scm: Remove (gnu system grub) import.
(operating-system-bootcfg): Refer to (gnu system grub) within the procedure.
Fixes <http://bugs.gnu.org/26791>.
Reported by Mark H Weaver <mhw@netris.org>.
* gnu/system.scm (<boot-parameters>, read-boot-parameters)
(read-boot-parameters-file): Move before first use of the
'boot-parameters' macro.
* gnu/system.scm (read-boot-parameters): Remove export.
(read-boot-parameters-file): New variable. Export it.
* guix/scripts/system.scm (profile-boot-parameters): Use
read-boot-parameters-file.
(profile-grub-entries): Use read-boot-parameters-file.
(reinstall-grub): Use read-boot-parameters-file.
(display-system-generation): Use read-boot-parameters-file.
* gnu/system.scm (bootable-kernel-arguments): New variable.
(operating-system-kernel-arguments): New variable.
(operating-system-bootcfg): Use operating-system-kernel-arguments.
(operating-system-boot-parameters): Use operating-system-kernel-arguments.
* gnu/services/base.scm (file-system-shepherd-services): New procedure.
(file-system-service-type): Use it as the SHEPHERD-ROOT-SERVICE-TYPE
extension.
(user-processes-service-type): Change to take a single 'grace-delay'
parameter.
(user-processes-service): Remove 'file-systems' parameter. Pass
GRACE-DELAY as the only value for the service.
* gnu/system.scm (essential-services): Adjust accordingly.