Subject: bug#26815: [PATCH v4 3/3] vm: Add UEFI loader to disk images.

From: Marius Bakke <[email-masked]>
Date: Sat, 20 May 2017 12:05:41 +0200

Mathieu Othacehe <[email-masked]> writes:

> Hi Marius,
>
>> I plan to make a generic "grub-standalone" variant. Will try to fit it
>> into the new bootloader API. The regular grub-efi variant won't cut it
>> because it can't update EFI variables on the target system, so we need
>> the "self-contained" grub snapshot generated by grub-mkstandalone(1).
>>
>> Also, the normal configuration file doesn't work with it, but a minimal
>> config that loads the real one at boot is okay. Not sure why!
>
> Ok, but don't we need to do it on system reconfigure too ?

Using "grub-mkstandalone" as an everyday bootloader is not a priority,
though it would be nice to support that too. It doesn't make much sense
to use that instead of "grub-efi" on a native system, but it can also
generate e.g. standalone PXE, u-boot and yeelong loaders.

>> On a related topic: The "device" field for grub-efi is a noop;
>> `grub-install` looks for "/boot/efi" only (or "--efi-directory").
>> Currently the example uses the ESP for "device", but it should not have
>> to be set. Not sure what to do about it, ideas?
>
> The "device" field of <bootloader> defaults to #f so maybe you can skip
> it ?

I tried that, but the "install-grub" procedure refused to function
without a device argument. Will probably have to implement an
"install-grub-efi" procedure, didn't look much into it yet.