From: Daan De Meyer Date: Wed, 25 Oct 2023 14:16:33 +0000 (+0200) Subject: Only add UEFI tools tree packages on architectures that support UEFI X-Git-Tag: v19~51^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e51798ddcf1b4e2e56e43d87af23f920724855c6;p=thirdparty%2Fmkosi.git Only add UEFI tools tree packages on architectures that support UEFI These are not built for other architectures on Fedora/CentOS so let's not try to add them there. --- diff --git a/mkosi/distributions/centos.py b/mkosi/distributions/centos.py index a04ebcdc9..49c2c0f5d 100644 --- a/mkosi/distributions/centos.py +++ b/mkosi/distributions/centos.py @@ -60,7 +60,7 @@ class Installer(DistributionInstaller): @classmethod def tools_tree_packages(cls) -> list[str]: - return [ + packages = [ "apt", "bash", "bubblewrap", @@ -73,11 +73,9 @@ class Installer(DistributionInstaller): "dnf", "dosfstools", "e2fsprogs", - "edk2-ovmf", "mtools", "openssh-clients", "openssl", - "pesign", "python3-cryptography", "qemu-kvm-core", "shadow-utils", @@ -96,6 +94,14 @@ class Installer(DistributionInstaller): "zstd", ] + if Architecture.native() in (Architecture.x86_64, Architecture.arm64): + packages += [ + "edk2-ovmf", + "pesign", + ] + + return packages + @classmethod def setup(cls, state: MkosiState) -> None: if GenericVersion(state.config.release) <= 7: diff --git a/mkosi/distributions/fedora.py b/mkosi/distributions/fedora.py index 3837c6e8f..2f2134caa 100644 --- a/mkosi/distributions/fedora.py +++ b/mkosi/distributions/fedora.py @@ -37,7 +37,7 @@ class Installer(DistributionInstaller): @classmethod def tools_tree_packages(cls) -> list[str]: - return [ + packages = [ "apt", "archlinux-keyring", "bash", @@ -52,16 +52,13 @@ class Installer(DistributionInstaller): "dnf5", "dosfstools", "e2fsprogs", - "edk2-ovmf", "erofs-utils", "mtools", "openssh-clients", "openssl", "pacman", - "pesign", "python3-cryptography", "qemu-kvm-core", - "sbsigntools", "shadow-utils", "socat", "squashfs-tools", @@ -80,6 +77,15 @@ class Installer(DistributionInstaller): "zypper", ] + if Architecture.native() in (Architecture.x86_64, Architecture.arm64): + packages += [ + "edk2-ovmf", + "pesign", + "sbsigntools", + ] + + return packages + @classmethod def setup(cls, state: MkosiState) -> None: gpgurls = (