[PATCH 1/6] kernel-build.eclass: cleanup dead symlinks after copying
Nowa Ammerlaan <[email protected]> Fri, 12 Jun 2026 20:57:59 +0200
| Newsgroups | gmane.linux.gentoo.devel |
|---|---|
| Message-ID | <[email protected]> |
Kernel commit eba6ffd126cd52358181ed5a179644a161f9c65f introduced a symlink between the scripts and the tools directory. We install the script directory in its entirety but the tools directory in a stripped down form to save space. This means this symlink is dead and triggers a QA notice. To resolve the problem we add here a find and cleanup after we are done copying everything to the installation directory. Signed-off-by: Nowa Ammerlaan <[email protected]> --- eclass/kernel-build.eclass | 3 +++ 1 file changed, 3 insertions(+) diff --git a/eclass/kernel-build.eclass b/eclass/kernel-build.eclass index 14785efd8eed..10f86423bb1b 100644 --- a/eclass/kernel-build.eclass +++ b/eclass/kernel-build.eclass @@ -482,6 +482,9 @@ kernel-build_src_install() { # add a dist-kernel identifier file echo "${CATEGORY}/${PF}:${SLOT}" > "${ED}${kernel_dir}/dist-kernel" || die + # Clean up dead symlinks + find -L "${ED}${kernel_dir}/" -type l -delete || die + # fix source tree and build dir symlinks dosym "../../../${kernel_dir}" "/lib/modules/${KV_FULL}/build" dosym "../../../${kernel_dir}" "/lib/modules/${KV_FULL}/source" -- 2.54.0