BIOS systems may or may not be able to boot from a GPT disk. Since we have no way to tell, just warn them. Resolves: rhbz#614585 --- storage/__init__.py | 20 +++++++++++++++++++- 1 files changed, 19 insertions(+), 1 deletions(-) diff --git a/storage/__init__.py b/storage/__init__.py index 464eebf..5214877 100644 --- a/storage/__init__.py +++ b/storage/__init__.py @@ -171,11 +171,29 @@ def storageComplete(anaconda): if anaconda.isKickstart: return + # Warn the user if they are trying to boot a GPT disk on a non-EFI system + # This may or may not work -- we have no way to tell, so just warn them + bootdisk = anaconda.id.bootloader.drivelist[0] + bootdisk = anaconda.id.storage.devicetree.getDeviceByName(bootdisk) + + if not iutil.isEfi() and bootdisk and bootdisk.format \ + and bootdisk.format.type == 'disklabel' \ + and bootdisk.format.labelType == 'gpt': + warning = _("\n\nWARNING:\n" + "You are using a GPT bootdisk on a non-EFI " + "system. This may not work, depending on you BIOS's " + "support for booting from GPT disks.") + log.warning("Using a GPT bootdisk on non-EFI system") + else: + warning = "" + + rc = anaconda.intf.messageWindow(_("Writing storage configuration to disk"), _("The partitioning options you have selected " "will now be written to disk. Any " "data on deleted or reformatted partitions " - "will be lost."), + "will be lost." + "%s") % (warning), type = "custom", custom_icon="warning", custom_buttons=[_("Go _back"), _("_Write changes to disk")], -- 1.7.3.4 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list