kernel_legacyhs: fix building/installing DTBs

A recent change in OE-Core kernel-devicetree.bbclass [1] changed appending
code for devicetree from exported do_*() functions to :append to their
unexported kernel_do_*() variant. But our copy of kernel_legacyhs.bbclass
doesn't define those, using kernel_legacyhs_do_*() names instead, due to
how function exporting works using the class name as a prefix.

In order to unreak devicetree building/installing, we need to provide
empty stubs for kernel_do_*() functions for the :append to work and
then call then at the end of our respective kernel_legacyhs_do_*()
functions.

[1] https://git.openembedded.org/openembedded-core/commit/?id=350281188267d0ad7c7e44a6ae3990edcfbe0300

Signed-off-by: Denys Dmytriyenko (TI) <denys@konsulko.com>
Signed-off-by: Ryan Eatmon <reatmon@ti.com>
This commit is contained in:
Denys Dmytriyenko (TI)
2026-08-12 16:32:41 -05:00
committed by Ryan Eatmon
parent 78741e4c2d
commit b2c5a3d2e6
@@ -354,6 +354,10 @@ addtask bundle_initramfs after do_install before do_deploy
KERNEL_DEBUG_TIMESTAMPS ??= "0"
kernel_do_compile() {
:
}
kernel_legacyhs_do_compile() {
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS MACHINE
@@ -398,6 +402,8 @@ kernel_legacyhs_do_compile() {
for typeformake in ${KERNEL_IMAGETYPE_FOR_MAKE} ; do
oe_runmake ${PARALLEL_MAKE} ${typeformake} ${KERNEL_EXTRA_ARGS} $use_alternate_initrd
done
kernel_do_compile
}
kernel_legacyhs_do_transform_kernel() {
@@ -458,6 +464,10 @@ do_compile_kernelmodules() {
}
addtask compile_kernelmodules after do_compile before do_strip
kernel_do_install() {
:
}
kernel_legacyhs_do_install() {
#
# First install the modules
@@ -498,6 +508,8 @@ kernel_legacyhs_do_install() {
install -m 0644 .config ${D}/${KERNEL_IMAGEDEST}/config-${KERNEL_VERSION}
install -m 0644 vmlinux ${D}/${KERNEL_IMAGEDEST}/vmlinux-${KERNEL_VERSION}
! [ -e Module.symvers ] || install -m 0644 Module.symvers ${D}/${KERNEL_IMAGEDEST}/Module.symvers-${KERNEL_VERSION}
kernel_do_install
}
# Must be ran no earlier than after do_kernel_checkout or else Makefile won't be in ${S}/Makefile
@@ -665,6 +677,10 @@ KERNEL_LOCALVERSION ??= ""
# helper function oe.kernel.get_localversion_file
export LOCALVERSION = "${KERNEL_LOCALVERSION}"
kernel_do_configure() {
:
}
kernel_legacyhs_do_configure() {
# fixes extra + in /lib/modules/2.6.37+
# $ scripts/setlocalversion . => +
@@ -689,6 +705,8 @@ kernel_legacyhs_do_configure() {
fi
${KERNEL_CONFIG_COMMAND}
kernel_do_configure
}
inherit cml1 pkgconfig
@@ -807,6 +825,10 @@ addtask sizecheck before do_install after do_strip
inherit kernel-artifact-names
kernel_do_deploy() {
:
}
kernel_legacyhs_do_deploy() {
deployDir="${DEPLOYDIR}"
if [ -n "${KERNEL_DEPLOYSUBDIR}" ]; then
@@ -857,6 +879,8 @@ kernel_legacyhs_do_deploy() {
fi
done
fi
kernel_do_deploy
}
# We deploy to filenames that include PKGV and PKGR, read the saved data to