]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
kernel: fix localversion in v6.3+
authorBruce Ashfield <bruce.ashfield@gmail.com>
Thu, 8 Feb 2024 11:52:45 +0000 (12:52 +0100)
committerSteve Sakoman <steve@sakoman.com>
Fri, 9 Feb 2024 16:38:05 +0000 (06:38 -1000)
commitd9273edae80978c34f8426f34f991b9598828aa9
tree199ac9ef8f78d6d3b18237516b49690595b441d0
parent17e20ce90b5b3abb5a597d4a5b470c8eaa3fd296
kernel: fix localversion in v6.3+

During testing of the v6.4 reference kernel, it was noticed that
on-target modules no longer matched the magic value of the running
kernel.

This was due to a different localversion in the cross built kernel
and the scripts / resources created on target.

This was due to changes in the setlocalversion script introduced
in the v6.3 series.

The .scmversion file is no longer used (or packaged) to inhibit
the addition of a "+" (through querying of the git status of the
kernel) or the setting of a local version.

We recently introduced the KERNEL_LOCALVERSION variable to allow
recipes to place a value in .scmversion, so we extend the use of
that variable to kernel-arch.bbclass and use it to set the
exported variable LOCALVERSION.

We must do it at the kernel-arch level, as the variable must be
exported in any kernel build to ensure that setlocalversion always
correctly sets the localversion.

Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Cherry-picked from master 765b13b7305c8d2f222cfc66d77c02e6a088c691

Signed-off-by: Andreas Helbech Kleist <andreaskleist@gmail.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
meta/classes/kernel-arch.bbclass
meta/classes/kernel.bbclass