Add new config option DISABLE_UEFI_32 to control mixed-mode EFI
on x86 builds. Closes: #1031424
This commit is contained in:
parent
dcbf4ea088
commit
7131e37390
6
CONF.sh
6
CONF.sh
|
@ -222,6 +222,12 @@ export JIGDO_CHECKSUM="md5"
|
||||||
#export amd64_MKISOFS="xorriso"
|
#export amd64_MKISOFS="xorriso"
|
||||||
#export amd64_MKISOFS_OPTS="-as mkisofs -r -checksum_algorithm_iso sha256,sha512"
|
#export amd64_MKISOFS_OPTS="-as mkisofs -r -checksum_algorithm_iso sha256,sha512"
|
||||||
|
|
||||||
|
# amd64 builds will also include 32-bit UEFI files by default, to
|
||||||
|
# allow for booting on weird machines with 64-bit CPUs but 32-bit
|
||||||
|
# firmware like Baytrail or some models of Apple iMac. To disable
|
||||||
|
# this, uncomment the following:
|
||||||
|
# export DISABLE_UEFI_32=1
|
||||||
|
|
||||||
# Keyring (defaults):
|
# Keyring (defaults):
|
||||||
#export ARCHIVE_KEYRING_PACKAGE=debian-archive-keyring
|
#export ARCHIVE_KEYRING_PACKAGE=debian-archive-keyring
|
||||||
# The path to the keyring file relative to $TDIR/archive-keyring/
|
# The path to the keyring file relative to $TDIR/archive-keyring/
|
||||||
|
|
|
@ -87,6 +87,8 @@ debian-cd (3.2.0) UNRELEASED; urgency=medium
|
||||||
[ Steve McIntyre ]
|
[ Steve McIntyre ]
|
||||||
* make-firmware-image: Add a list file to show what's included in
|
* make-firmware-image: Add a list file to show what's included in
|
||||||
the firmware archives.
|
the firmware archives.
|
||||||
|
* Add new config option DISABLE_UEFI_32 to control mixed-mode EFI on
|
||||||
|
x86 builds. Closes: #1031424
|
||||||
|
|
||||||
-- Cyril Brulebois <kibi@debian.org> Wed, 08 Feb 2023 10:44:19 +0100
|
-- Cyril Brulebois <kibi@debian.org> Wed, 08 Feb 2023 10:44:19 +0100
|
||||||
|
|
||||||
|
|
|
@ -35,6 +35,11 @@ else
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# amd64 builds will also include 32-bit UEFI files by default, to
|
||||||
|
# allow for booting on weird machines with 64-bit CPUs but 32-bit
|
||||||
|
# firmware like Baytrail or some models of Apple iMac. Set
|
||||||
|
# DISABLE_UEFI_32=1 in your config to disable this.
|
||||||
|
|
||||||
N=$1
|
N=$1
|
||||||
CDDIR=$2
|
CDDIR=$2
|
||||||
BOOTDIR=
|
BOOTDIR=
|
||||||
|
@ -79,10 +84,16 @@ else
|
||||||
INSTALLDIR="$INSTALLDIR_i386"
|
INSTALLDIR="$INSTALLDIR_i386"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ $ARCH = i386 ]; then
|
if [ $ARCH = amd64 ]; then
|
||||||
BOOT_IMAGES="cdrom/initrd.gz cdrom/vmlinuz cdrom/cd_info_i386"
|
BOOT_IMAGES="cdrom/initrd.gz cdrom/vmlinuz cdrom/cd_info_amd64 "
|
||||||
|
if [ "$DISABLE_UEFI_32"x = "1"x ]; then
|
||||||
|
echo " NOT retrieving i386 EFI files"
|
||||||
|
else
|
||||||
|
echo " Retrieving i386 EFI files also on amd64 build"
|
||||||
|
BOOT_IMAGES="$BOOT_IMAGES cdrom/cd_info_i386"
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
BOOT_IMAGES="cdrom/initrd.gz cdrom/vmlinuz cdrom/cd_info_i386 cdrom/cd_info_amd64 "
|
BOOT_IMAGES="cdrom/initrd.gz cdrom/vmlinuz cdrom/cd_info_i386"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Download boot images.
|
# Download boot images.
|
||||||
|
@ -196,8 +207,9 @@ mkdir -p boot$N/isolinux
|
||||||
# Isolinux setup including config and help files comes from d-i.
|
# Isolinux setup including config and help files comes from d-i.
|
||||||
cat cdrom/cd_info_$ARCH | (cd boot$N/isolinux/; tar zx)
|
cat cdrom/cd_info_$ARCH | (cd boot$N/isolinux/; tar zx)
|
||||||
mv boot$N/isolinux/grub boot$N/isolinux/grub-$ARCH
|
mv boot$N/isolinux/grub boot$N/isolinux/grub-$ARCH
|
||||||
if [ $ARCH = amd64 ]; then
|
if [ $ARCH = amd64 ] && [ "$DISABLE_UEFI_32"x != "1"x ]; then
|
||||||
# Also extract i386 grub files, for Bay Trail etc.
|
# Also extract i386 grub files, for Bay Trail etc.
|
||||||
|
echo " Extracting i386 EFI files also on amd64 build"
|
||||||
cat cdrom/cd_info_i386 | (cd boot$N/isolinux/; tar zx ./grub)
|
cat cdrom/cd_info_i386 | (cd boot$N/isolinux/; tar zx ./grub)
|
||||||
mv boot$N/isolinux/grub boot$N/isolinux/grub-i386
|
mv boot$N/isolinux/grub boot$N/isolinux/grub-i386
|
||||||
fi
|
fi
|
||||||
|
@ -410,7 +422,6 @@ set_default_desktop
|
||||||
rm -rf cdrom
|
rm -rf cdrom
|
||||||
|
|
||||||
if [ -d boot$N/isolinux/grub-$ARCH ] && [ $BOOT_EFI -ne 0 ] ; then
|
if [ -d boot$N/isolinux/grub-$ARCH ] && [ $BOOT_EFI -ne 0 ] ; then
|
||||||
echo " Adding EFI boot code for $ARCH on CD$N"
|
|
||||||
|
|
||||||
# Move GRUB files to the right places
|
# Move GRUB files to the right places
|
||||||
mkdir -p $CDDIR/EFI/boot
|
mkdir -p $CDDIR/EFI/boot
|
||||||
|
@ -424,6 +435,8 @@ if [ -d boot$N/isolinux/grub-$ARCH ] && [ $BOOT_EFI -ne 0 ] ; then
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
echo " Adding EFI boot code for $grub_arch on CD$N"
|
||||||
|
|
||||||
mcopy -n -s -i $dir/efi.img '::efi/*' $CDDIR/EFI
|
mcopy -n -s -i $dir/efi.img '::efi/*' $CDDIR/EFI
|
||||||
|
|
||||||
# Save space. if we have both files, that means we have shim
|
# Save space. if we have both files, that means we have shim
|
||||||
|
|
Loading…
Reference in New Issue