From f247b36fc6df2694a347f5305eeb7f927d7c0ffe Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 2 Sep 2023 22:17:17 +0100 Subject: gentoo auto-resync : 02:09:2023 - 22:17:17 --- eclass/Manifest.gz | Bin 38504 -> 38506 bytes eclass/dist-kernel-utils.eclass | 11 ++++++----- eclass/kernel-build.eclass | 14 ++++++++++++++ 3 files changed, 20 insertions(+), 5 deletions(-) (limited to 'eclass') diff --git a/eclass/Manifest.gz b/eclass/Manifest.gz index 99d073f6db4e..785335ae3cd5 100644 Binary files a/eclass/Manifest.gz and b/eclass/Manifest.gz differ diff --git a/eclass/dist-kernel-utils.eclass b/eclass/dist-kernel-utils.eclass index b2e9df6746e3..1a55424a97ef 100644 --- a/eclass/dist-kernel-utils.eclass +++ b/eclass/dist-kernel-utils.eclass @@ -71,8 +71,12 @@ dist-kernel_get_image_path() { amd64|x86) echo arch/x86/boot/bzImage ;; - arm64) - echo arch/arm64/boot/Image.gz + arm64|riscv) + if [[ ${KERNEL_IUSE_SECUREBOOT} ]] && use secureboot; then + echo arch/${ARCH}/boot/vmlinuz.efi + else + echo arch/${ARCH}/boot/Image.gz + fi ;; arm) echo arch/arm/boot/zImage @@ -83,9 +87,6 @@ dist-kernel_get_image_path() { # substitutions in the code echo ./vmlinux ;; - riscv) - echo arch/riscv/boot/Image.gz - ;; *) die "${FUNCNAME}: unsupported ARCH=${ARCH}" ;; diff --git a/eclass/kernel-build.eclass b/eclass/kernel-build.eclass index ca105ee1f133..0c40e8033fe2 100644 --- a/eclass/kernel-build.eclass +++ b/eclass/kernel-build.eclass @@ -436,6 +436,20 @@ kernel-build_merge_configs() { fi fi + if [[ ${KERNEL_IUSE_SECUREBOOT} ]]; then + if use secureboot; then + # This only effects arm64 and riscv where the bootable image may + # contain its own decompressor (zboot). If enabled we get a + # sign-able efi file. + cat <<-EOF > "${WORKDIR}/secureboot.config" || die + ## Enable zboot for signing + CONFIG_EFI_ZBOOT=y + EOF + + merge_configs+=( "${WORKDIR}/secureboot.config" ) + fi + fi + if [[ ${#user_configs[@]} -gt 0 ]]; then elog "User config files are being applied:" local x -- cgit v1.2.3