Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 913542 - sys-kernel/gentoo-kernel-bin: emerge --config fails on arm64
Summary: sys-kernel/gentoo-kernel-bin: emerge --config fails on arm64
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: ARM64 Linux
: Normal normal
Assignee: Distribution Kernel Project
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2023-09-03 06:22 UTC by Kirill Chibisov
Modified: 2023-09-04 13:14 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge failure (emerge-failure.txt,10.36 KB, text/plain)
2023-09-03 06:22 UTC, Kirill Chibisov
Details
emerge --info (emerge-info.txt,6.62 KB, text/plain)
2023-09-03 06:22 UTC, Kirill Chibisov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kirill Chibisov 2023-09-03 06:22:03 UTC
Created attachment 869301 [details]
emerge failure

The kernel deployment started to fail with the sys-kernel/installkernel-gentoo. I was told in #gentoo that it might be related to some recent eclass changes, such as https://github.com/gentoo/gentoo/commit/e2b8c79419c258224a91807e30d57b075703f or https://github.com/gentoo/gentoo/commit/661829cb3563d6fde27ac540fc1b42d64ef02541
Comment 1 Kirill Chibisov 2023-09-03 06:22:47 UTC
Created attachment 869302 [details]
emerge --info
Comment 2 Nowa Ammerlaan gentoo-dev 2023-09-03 06:30:01 UTC
We build the gentoo-kernel-bin gpkg with USE=secureboot enabled. This changes the name of the image. If the user has this flag disabled when emerging gentoo-kernel-bin the eclass thinks the name is Image.gz while in the gpkg we have vmlinuz.efi.

Not sure what the best fix is for this yet
Comment 3 Nowa Ammerlaan gentoo-dev 2023-09-03 06:51:48 UTC
Probably what we need is an extra || ${PN} == *-bin on line 75 of dist-kernel-utils.eclass
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-09-03 06:56:12 UTC
I'm a bit confused about the original fix too. Do the commits which closed bug 897684 actually help if you set the config option for ZBOOT *without* SB?
Comment 5 Nowa Ammerlaan gentoo-dev 2023-09-03 07:04:34 UTC
(In reply to Sam James from comment #4)
> I'm a bit confused about the original fix too. Do the commits which closed
> bug 897684 actually help if you set the config option for ZBOOT *without* SB?

They don't. If we want it to work with user config overrides as well then we have to dynamically determine the name of the built image.
Comment 6 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2023-09-03 11:58:22 UTC
Hmm, now I'm worried that building the package with USE=secureboot effectively means that all *-bin users are exposed to what was supposed to be an experimental feature.
Comment 7 Nowa Ammerlaan gentoo-dev 2023-09-03 18:29:36 UTC
@Kirill Chibisov I don't have an arm64 machine to test on but in theory the patches from [1] should fix the problem. Would you be willing to verify that it actually works as intended?


[1] https://github.com/gentoo/gentoo/pull/32587
Comment 8 Kirill Chibisov 2023-09-04 00:00:35 UTC
Besides manifest regeneration (which is missed on the given patches).

Tested-by: Kirill Chibisov contact@kchibisov.com
Comment 9 Larry the Git Cow gentoo-dev 2023-09-04 13:14:35 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=284ab6c61919959b2993cfdd5863d3b677c7bfca

commit 284ab6c61919959b2993cfdd5863d3b677c7bfca
Author:     Andrew Ammerlaan <andrewammerlaan@gentoo.org>
AuthorDate: 2023-09-03 18:20:51 +0000
Commit:     Michał Górny <mgorny@gentoo.org>
CommitDate: 2023-09-04 13:14:16 +0000

    sys-kernel/gentoo-kernel-bin: specify that 6.4.14 has EFI_ZBOOT enabled
    
    Closes: https://bugs.gentoo.org/913542
    Signed-off-by: Andrew Ammerlaan <andrewammerlaan@gentoo.org>
    Closes: https://github.com/gentoo/gentoo/pull/32587
    Signed-off-by: Michał Górny <mgorny@gentoo.org>

 sys-kernel/gentoo-kernel-bin/gentoo-kernel-bin-6.4.14.ebuild | 1 +
 1 file changed, 1 insertion(+)