summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-01-26 17:57:51 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-01-26 22:20:32 +0000
commit23737c8ac75191b3a463cfd64cb7266e0cbac273 (patch)
treeb37e601411a832b42b4175ebcf44ad541cb53057
parent7323bb0ee1f0ddcaf4c8c764abe4729dbe7bfcb8 (diff)
downloadpoky-23737c8ac75191b3a463cfd64cb7266e0cbac273.tar.gz
kernel/linux-kernel-base: Fix kernel build artefact determinism issues
With the 6.1 kernel we've seen reproducibility/determinism issues where the kernel seems to rebuild headers referencing the hostname or local user. kernel-devsrc building after the kernel seemed to trigger it in some cases. Moving the definitions to the bbclass used by all the kernel recipe code including kernel-devsrc seems to be the best way to ensure this doesn't happen. (From OE-Core rev: 60681baa97daf4f3856453c34d6be08b6771a81b) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes-recipe/kernel.bbclass3
-rw-r--r--meta/classes-recipe/linux-kernel-base.bbclass4
2 files changed, 4 insertions, 3 deletions
diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass
index bd3b6471c6..4fbe84c4e4 100644
--- a/meta/classes-recipe/kernel.bbclass
+++ b/meta/classes-recipe/kernel.bbclass
@@ -210,9 +210,6 @@ PACKAGES_DYNAMIC += "^${KERNEL_PACKAGE_NAME}-firmware-.*"
210 210
211export OS = "${TARGET_OS}" 211export OS = "${TARGET_OS}"
212export CROSS_COMPILE = "${TARGET_PREFIX}" 212export CROSS_COMPILE = "${TARGET_PREFIX}"
213export KBUILD_BUILD_VERSION = "1"
214export KBUILD_BUILD_USER ?= "oe-user"
215export KBUILD_BUILD_HOST ?= "oe-host"
216 213
217KERNEL_RELEASE ?= "${KERNEL_VERSION}" 214KERNEL_RELEASE ?= "${KERNEL_VERSION}"
218 215
diff --git a/meta/classes-recipe/linux-kernel-base.bbclass b/meta/classes-recipe/linux-kernel-base.bbclass
index cb2212c948..65cc48f304 100644
--- a/meta/classes-recipe/linux-kernel-base.bbclass
+++ b/meta/classes-recipe/linux-kernel-base.bbclass
@@ -43,5 +43,9 @@ def linux_module_packages(s, d):
43 suffix = "" 43 suffix = ""
44 return " ".join(map(lambda s: "kernel-module-%s%s" % (s.lower().replace('_', '-').replace('@', '+'), suffix), s.split())) 44 return " ".join(map(lambda s: "kernel-module-%s%s" % (s.lower().replace('_', '-').replace('@', '+'), suffix), s.split()))
45 45
46export KBUILD_BUILD_VERSION = "1"
47export KBUILD_BUILD_USER ?= "oe-user"
48export KBUILD_BUILD_HOST ?= "oe-host"
49
46# that's all 50# that's all
47 51