me
/
guix
Archived
1
0
Fork 0

image: Do not allow BIOS bootloader and GPT.

When using grub-bootloader with a GPT image, GRUB will fail during
installation with a cryptic error message.

* gnu/system/image.scm (system-disk-image): Raise an error when trying to use
a non-EFI compatible bootloader with a GPT image partitioning.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
Mathieu Othacehe 2023-09-09 17:57:26 +02:00
parent e5ed1712da
commit 6bd17a0806
No known key found for this signature in database
GPG Key ID: 8354763531769CA6
1 changed files with 7 additions and 0 deletions

View File

@ -530,6 +530,13 @@ used in the image."
(image-partition-table-type image)))
(else "")))
(when (and (gpt-image? image)
(not
(memq (bootloader-name bootloader) '(grub-efi grub-efi32))))
(raise
(formatted-message
(G_ "EFI bootloader required with GPT partitioning"))))
(let* ((format (image-format image))
(image-type (format->image-type format))
(image-type-options (genimage-type-options image-type image))