Skip to content
Snippets Groups Projects
Commit 87e4e3c4 authored by Philip's avatar Philip
Browse files

[bootloader] improve efi check and don't fail if install path is null

parent a57b08c2
No related branches found
No related tags found
No related merge requests found
...@@ -240,7 +240,13 @@ def install_grub(efi_directory, fw_type): ...@@ -240,7 +240,13 @@ def install_grub(efi_directory, fw_type):
efi_file_target[efi_bitness]]) efi_file_target[efi_bitness]])
else: else:
print("Bootloader: grub (bios)") print("Bootloader: grub (bios)")
if libcalamares.globalstorage.value("bootLoader") is None:
return
boot_loader = libcalamares.globalstorage.value("bootLoader") boot_loader = libcalamares.globalstorage.value("bootLoader")
if boot_loader["installPath"] is None:
return
check_target_env_call([libcalamares.job.configuration["grubInstall"], check_target_env_call([libcalamares.job.configuration["grubInstall"],
"--target=i386-pc", "--target=i386-pc",
"--recheck", "--recheck",
...@@ -282,10 +288,12 @@ def run(): ...@@ -282,10 +288,12 @@ def run():
:return: :return:
""" """
if libcalamares.globalstorage.value("bootLoader") is None:
return None
fw_type = libcalamares.globalstorage.value("firmwareType") fw_type = libcalamares.globalstorage.value("firmwareType")
if libcalamares.globalstorage.value("bootLoader") is None and fw_type != "efi":
return None
prepare_bootloader(fw_type) prepare_bootloader(fw_type)
return None return None
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment