From 0b39955d14600257a6eafc211fd68a933c69a0e9 Mon Sep 17 00:00:00 2001 From: Steve Sakoman Date: Thu, 15 Feb 2024 15:45:23 -1000 Subject: Revert "kernel: fix localversion in v6.3+" This reverts commit d9273edae80978c34f8426f34f991b9598828aa9. This commit is causing breakage for some vendor kernel builds. (From OE-Core rev: 59cc2e75c15f8c6371a4c4a3b7bd2e6c3f145fbc) Signed-off-by: Steve Sakoman --- meta/classes/kernel-arch.bbclass | 7 ------- meta/classes/kernel.bbclass | 10 ++-------- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/meta/classes/kernel-arch.bbclass b/meta/classes/kernel-arch.bbclass index 0a79dea0af..4cd08b96fb 100644 --- a/meta/classes/kernel-arch.bbclass +++ b/meta/classes/kernel-arch.bbclass @@ -66,10 +66,3 @@ KERNEL_LD = "${CCACHE}${HOST_PREFIX}ld.bfd ${HOST_LD_KERNEL_ARCH}" KERNEL_AR = "${CCACHE}${HOST_PREFIX}ar ${HOST_AR_KERNEL_ARCH}" TOOLCHAIN ?= "gcc" -# 6.3+ requires the variable LOCALVERSION to be set to not get a "+" in -# the local version. Having it empty means nothing will be added, and any -# value will be appended to the local kernel version. This replaces the -# use of .scmversion file for setting a localversion without using -# the CONFIG_LOCALVERSION option. -KERNEL_LOCALVERSION ??= "" -export LOCALVERSION ?= "${KERNEL_LOCALVERSION}" diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass index 940f1a3cf4..5951347361 100644 --- a/meta/classes/kernel.bbclass +++ b/meta/classes/kernel.bbclass @@ -418,7 +418,7 @@ do_compile_kernelmodules() { if (grep -q -i -e '^CONFIG_MODULES=y$' ${B}/.config); then oe_runmake -C ${B} ${PARALLEL_MAKE} modules ${KERNEL_EXTRA_ARGS} - # Module.symvers gets updated during the + # Module.symvers gets updated during the # building of the kernel modules. We need to # update this in the shared workdir since some # external kernel modules has a dependency on @@ -635,13 +635,7 @@ kernel_do_configure() { # $ scripts/setlocalversion . => + # $ make kernelversion => 2.6.37 # $ make kernelrelease => 2.6.37+ - # See kernel-arch.bbclass for post v6.3 removal of the extra - # + in localversion. .scmversion is no longer used, and the - # variable LOCALVERSION must be used - if [ ! -e ${B}/.scmversion -a ! -e ${S}/.scmversion ]; then - echo ${KERNEL_LOCALVERSION} > ${B}/.scmversion - echo ${KERNEL_LOCALVERSION} > ${S}/.scmversion - fi + touch ${B}/.scmversion ${S}/.scmversion if [ "${S}" != "${B}" ] && [ -f "${S}/.config" ] && [ ! -f "${B}/.config" ]; then mv "${S}/.config" "${B}/.config" -- cgit v1.2.3-54-g00ecf