From: Andreas Helbech Kleist <andreaskleist@gmail.com>
To: openembedded-core@lists.openembedded.org
Cc: reatmon@ti.com
Subject: [kirkstone][PATCH 1/3] kernel.bbclass: introduce KERNEL_LOCALVERSION
Date: Thu, 22 Feb 2024 11:35:43 +0100 [thread overview]
Message-ID: <20240222103545.2970387-2-andreaskleist@gmail.com> (raw)
In-Reply-To: <20240222103545.2970387-1-andreaskleist@gmail.com>
From: Ming Liu <liu.ming50@gmail.com>
Just like UBOOT_LOCALVERSION, an end user can set KERNEL_LOCALVERSION
to append a string to the name of the local version of the kernel
image.
Signed-off-by: Ming Liu <liu.ming50@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
cherry-picked from master 229435a52f36ddec5f85fb6d5ccd42044b688397
Signed-off-by: Andreas Helbech Kleist <andreaskleist@gmail.com>
---
meta/classes/kernel.bbclass | 6 +++++-
meta/conf/documentation.conf | 1 +
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 5951347361..80fb1879b0 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -614,6 +614,7 @@ do_shared_workdir () {
# We don't need to stage anything, not the modules/firmware since those would clash with linux-firmware
SYSROOT_DIRS = ""
+KERNEL_LOCALVERSION ??= ""
KERNEL_CONFIG_COMMAND ?= "oe_runmake_call -C ${S} O=${B} olddefconfig || oe_runmake -C ${S} O=${B} oldnoconfig"
python check_oldest_kernel() {
@@ -635,7 +636,10 @@ kernel_do_configure() {
# $ scripts/setlocalversion . => +
# $ make kernelversion => 2.6.37
# $ make kernelrelease => 2.6.37+
- touch ${B}/.scmversion ${S}/.scmversion
+ if [ ! -e ${B}/.scmversion -a ! -e ${S}/.scmversion ]; then
+ echo ${KERNEL_LOCALVERSION} > ${B}/.scmversion
+ echo ${KERNEL_LOCALVERSION} > ${S}/.scmversion
+ fi
if [ "${S}" != "${B}" ] && [ -f "${S}/.config" ] && [ ! -f "${B}/.config" ]; then
mv "${S}/.config" "${B}/.config"
diff --git a/meta/conf/documentation.conf b/meta/conf/documentation.conf
index ab2addb321..e55bfa288d 100644
--- a/meta/conf/documentation.conf
+++ b/meta/conf/documentation.conf
@@ -253,6 +253,7 @@ KERNEL_MODULE_PROBECONF[doc] = "Lists kernel modules for which the build system
KERNEL_PACKAGE_NAME[doc] = "Name prefix for kernel packages. Defaults to 'kernel'."
KERNEL_PATH[doc] = "The location of the kernel sources. This variable is set to the value of the STAGING_KERNEL_DIR within the module class (module.bbclass)."
KERNEL_SRC[doc] = "The location of the kernel sources. This variable is set to the value of the STAGING_KERNEL_DIR within the module class (module.bbclass)."
+KERNEL_LOCALVERSION[doc] = "Appends a string to the name of the local version of the kernel image."
KFEATURE_DESCRIPTION[doc] = "Provides a short description of a configuration fragment. You use this variable in the .scc file that describes a configuration fragment file."
KMACHINE[doc] = "The machine as known by the kernel."
KTYPE[doc] = "Defines the kernel type to be used in assembling the configuration."
--
2.43.2
next prev parent reply other threads:[~2024-02-22 10:35 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-22 10:35 [kirkstone][PATCH 0/3] kernel: Backport v6.3+ localversion fixes Andreas Helbech Kleist
2024-02-22 10:35 ` Andreas Helbech Kleist [this message]
2024-02-22 10:35 ` [kirkstone][PATCH 2/3] kernel: fix localversion in v6.3+ Andreas Helbech Kleist
2024-02-22 10:35 ` [kirkstone][PATCH 3/3] kernel: make LOCALVERSION consistent between recipes Andreas Helbech Kleist
2024-02-22 21:51 ` Ryan Eatmon
2024-02-22 21:56 ` [OE-core] " Bruce Ashfield
2024-02-22 22:46 ` Ryan Eatmon
[not found] ` <17B650DBED7FC1F0.14827@lists.openembedded.org>
2024-02-23 17:11 ` Ryan Eatmon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240222103545.2970387-2-andreaskleist@gmail.com \
--to=andreaskleist@gmail.com \
--cc=openembedded-core@lists.openembedded.org \
--cc=reatmon@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox