kernel-2.eclass: While chkin if kern ver is pres, support subdirs

Closes: https://bugs.gentoo.org/974322

Signed-off-by: Mike Pagano <mpagano@gentoo.org>
This commit is contained in:
Mike Pagano
2026-05-09 16:01:03 -04:00
parent ac14d1f911
commit f6c28ea0d0

View File

@@ -1123,13 +1123,14 @@ unipatch() {
# Iterate through patch and look for OKV
if [[ -n "${K_WANT_GENPATCHES}" ]]; then
KV_PATCH_FOUND=
for file in ${KPATCH_DIR}/*; do
while IFS= read -r -d '' file; do
filename="${file##*/}"
if [[ "$filename" == *"${OKV}"* ]]; then
KV_PATCH_FOUND=yes
break;
fi
done
done < <(find "$KPATCH_DIR" -type f -print0)
if [[ -z ${KV_PATCH_FOUND} ]]; then
eerror "GENPATCHES does not contain linux patch ${OKV}"
eerror "Please check your ebuild for the proper K_GENPATCHES_VER=N"