#904062 Allow concurrent installation of grub-pc and grub-efi-ami64

Package:
grub-efi-amd64
Source:
grub2
Description:
GRand Unified Bootloader, version 2 (EFI-AMD64 version)
Submitter:
"Daniel Richard G."
Date:
2025-01-13 06:03:02 UTC
Severity:
wishlist
#904062#5
Date:
2018-07-19 02:04:46 UTC
From:
To:
Currently, you can have both grub-{pc,efi-amd64}-bin installed, but you
can only have one or the other of grub-{pc,efi-amd64}, as the packages
conflict with each other. This means that only one grub-install --target
is supported in Debian's configuration framework at any one time.

(It is already possible to install both grub-*-bin packages and invoke
grub-install with the desired --target manually, but this occurs outside
of the Debian framework and so is not a good long-term solution.)

I would like to request making it possible to install both packages
simultaneously, with an appropriate configuration mechanism to
disable one, both, or none. There are at least a couple of use cases
I can see for this:

1. Assembling system images that can support both BIOS and EFI booting
   without needing to install/remove any packages to switch from one
   mode to the other;

2. A Debian install on e.g. a portable USB hard drive with a hybrid
   MBR/GPT partition table that supports *both* the BIOS and EFI
   boot paths.

#904062#10
Date:
2025-01-13 06:01:16 UTC
From:
To:
I just tried creating a build of GRUB that had had the
Conflicts/Replaces between grub-pc and the various grub-efi variants
crudely hacked out. These packages seemed to install without problems
on a freshly installed Debian Sid system, and the EFI bootloader still
automatically installs when running `dpkg-reconfigure
--priority=critical grub-efi-amd64`. However running `dpkg-reconfigure
--priority=critical grub-pc` only results in the GRUB config being
regenerated, the BIOS bootloader isn't installed. Probably needs some
changes to the postinst to get that to work. (I did verify that I can
`grub-install` the BIOS bootloader to this system without problems, and
yes, I am using a GPT disk with both an EFI system partition and a
bios-boot partition.)

Will probably be looking into this further in the future.