From bb32314f9fbad9f4811009badab79e88755fc847 Mon Sep 17 00:00:00 2001 From: Tobias Powalowski Date: Fri, 3 Feb 2023 14:04:31 +0100 Subject: [PATCH] fix GUID on BIOS partitioning --- usr/lib/archboot/installer/autoprepare.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/usr/lib/archboot/installer/autoprepare.sh b/usr/lib/archboot/installer/autoprepare.sh index d8ce4de16..fcd05699a 100644 --- a/usr/lib/archboot/installer/autoprepare.sh +++ b/usr/lib/archboot/installer/autoprepare.sh @@ -198,7 +198,9 @@ _autoprepare() { sgdisk --clear "${_DISK}" &>"${_NO_LOG}" # create actual partitions sgdisk --new="${_GPT_BIOS_GRUB_DEV_NUM}":0:+"${_GPT_BIOS_GRUB_DEV_SIZE}"M --typecode="${_GPT_BIOS_GRUB_DEV_NUM}":EF02 --change-name="${_GPT_BIOS_GRUB_DEV_NUM}":BIOS_GRUB "${_DISK}" >"${_LOG}" - sgdisk --new="${_UEFISYSDEV_NUM}":0:+"${_UEFISYSDEV_SIZE}"M --typecode="${_UEFISYSDEV_NUM}":EF00 --change-name="${_UEFISYSDEV_NUM}":EFI_SYSTEM "${_DISK}" >"${_LOG}" + if [[ -n "${_UEFI_BOOT}" ]]; then + sgdisk --new="${_UEFISYSDEV_NUM}":0:+"${_UEFISYSDEV_SIZE}"M --typecode="${_UEFISYSDEV_NUM}":EF00 --change-name="${_UEFISYSDEV_NUM}":EFI_SYSTEM "${_DISK}" >"${_LOG}" + fi if [[ -n "${_UEFISYS_BOOTDEV}" ]]; then # set the legacy BIOS boot 2bit attribute sgdisk --attributes="${_UEFISYSDEV_NUM}":set:2 "${_DISK}" >"${_LOG}"