summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTom Hochstein <tom.hochstein@nxp.com>2025-12-15 12:17:10 -0600
committerTom Hochstein <tom.hochstein@nxp.com>2025-12-15 12:38:03 -0600
commite6a138da453e94b9042003b5959c6ac2d2ea7221 (patch)
tree1b803cf2239672b890ab860dd6e42195fa808c52
parent1f1dd28237aeaf07604a7f5d3c09819339c7be94 (diff)
downloadmeta-freescale-e6a138da453e94b9042003b5959c6ac2d2ea7221.tar.gz
fsl-kernel-localversion: Fix duplicate LOCALVERSION
The kernel version contains LOCALVERSION twice. For example, for LOCALVERSION=nxp-next: ``` $ cat tmp/work/imx95evk-poky-linux/linux-imx/6.18.y+git/build/include/generated/utsrelease.h #define UTS_RELEASE "6.18.0-nxp-next-nxp-next-06195-gb61baedaf5d5" ``` The problem is kernel-yocto.bbclass adds LOCALVERSION via .config if LINUX_VERSION_EXTENSION is not empty, and the build itself adds it because fsl-kernel-localversion.bbclass sets CONFIG_LOCALVERSION_AUTO=y whenever SCMVERSION is enabled. Fix by clearing LINUX_VERSION_EXTENSION if SCMVERSION is enabled. Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
-rw-r--r--classes/fsl-kernel-localversion.bbclass3
1 files changed, 2 insertions, 1 deletions
diff --git a/classes/fsl-kernel-localversion.bbclass b/classes/fsl-kernel-localversion.bbclass
index 9ef0a62f6..fae3fe1d9 100644
--- a/classes/fsl-kernel-localversion.bbclass
+++ b/classes/fsl-kernel-localversion.bbclass
@@ -13,7 +13,8 @@ SCMVERSION ??= "y"
13LOCALVERSION ??= "+fslc" 13LOCALVERSION ??= "+fslc"
14 14
15# LINUX_VERSION_EXTENSION is used as CONFIG_LOCALVERSION by kernel-yocto class 15# LINUX_VERSION_EXTENSION is used as CONFIG_LOCALVERSION by kernel-yocto class
16LINUX_VERSION_EXTENSION ?= "${LOCALVERSION}" 16LINUX_VERSION_EXTENSION ?= \
17 "${@bb.utils.contains('SCMVERSION', 'y', '', '${LOCALVERSION}', d)}"
17 18
18do_kernel_localversion[dirs] += "${S} ${B}" 19do_kernel_localversion[dirs] += "${S} ${B}"
19do_kernel_localversion() { 20do_kernel_localversion() {