If the config still exists, check it for CONFIG_EFI_ZBOOT, if it is
then the name of the kernel image will be different. We already
introduced the KERNEL_EFI_ZBOOT=1 variable to instruct the dist-kernel_get_image_path() function to look for this different name.
We however forgot to add some logic to set it for the
reinstall_initramfs() path which is called via linux-mod-r1.eclass
by for example sys-fs/zfs-kmod[dist-kernel,initramfs]. This ebuild
has no information on whether the target kernel was built with ZBOOT
enabled or not. So we add now some logic to the eclass to check this.
Closes:
https://bugs.gentoo.org/960603
Signed-off-by: Nowa Ammerlaan <
[email protected]>
---
eclass/dist-kernel-utils.eclass | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/eclass/dist-kernel-utils.eclass b/eclass/dist-kernel-utils.eclass index 49977c18795a..975efd2d63c8 100644
--- a/eclass/dist-kernel-utils.eclass
+++ b/eclass/dist-kernel-utils.eclass
@@ -180,7 +180,14 @@ dist-kernel_reinstall_initramfs() {
local kernel_dir=${1:-${KV_DIR}}
local ver=${2:-${KV_FULL}}
+ # If this is set it will have an effect on the name of the output
+ # image. Set this variable to track this setting.
+ if grep -q "CONFIG_EFI_ZBOOT=y" "${kernel_dir}/.config"; then
+ KERNEL_EFI_ZBOOT=1
+ fi
+
local image_path=${kernel_dir}/$(dist-kernel_get_image_path)
+
if [[ ! -f ${image_path} ]]; then
eerror "Kernel install missing, image not found:"
eerror " ${image_path}"
--
2.50.1
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)