Skip to content

Commit

Permalink
Merge pull request commontorizon#6 from lucas-akira/arm64-kernel-5.19…
Browse files Browse the repository at this point in the history
…-support

kernel-devsrc.bbappend: support arm64 kernel 5.19+ on Kirkstone
  • Loading branch information
jsrc27 authored Feb 1, 2024
2 parents e60ba5d + 5af2bf4 commit 002fc19
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions recipes-kernel/linux/kernel-devsrc.bbappend
Original file line number Diff line number Diff line change
@@ -1,4 +1,33 @@
do_install:append() {

# Adapted backport from the following langdale commit:
# https://git.openembedded.org/openembedded-core/commit/meta/recipes-kernel/linux/kernel-devsrc.bb?h=langdale&id=7b195d7be1d0db1ad8024494ff990717bd30aea4
######################################################################################################
if [ "${ARCH}" = "arm64" ]; then
(
cd ${S}
# Needed for kernel 5.19+
cp -a --parents arch/arm64/tools/gen-sysreg.awk $kerneldir/build/ 2>/dev/null || :
cp -a --parents arch/arm64/tools/sysreg $kerneldir/build/ 2>/dev/null || :

if [ -e $kerneldir/build/arch/arm64/tools/gen-sysreg.awk ]; then
sed -i -e "s,#!.*awk.*,#!${USRBINPATH}/env awk," $kerneldir/build/arch/arm64/tools/gen-sysreg.awk
fi

chown -R root:root $kerneldir/build/arch/arm64/tools/
)
fi

if [ "${ARCH}" = "arm" ]; then
(
cd ${S}
cp -a --parents arch/arm/tools/gen-sysreg.awk $kerneldir/build/ 2>/dev/null || :

chown -R root:root $kerneldir/build/arch/arm/tools/
)
fi
######################################################################################################

mv $kerneldir/build $kerneldir/linux
tar cjfv ${D}/usr/src/linux.tar.bz2 -C $kerneldir linux
rm -rf ${D}/usr/lib ${D}/usr/src/kernel
Expand Down

0 comments on commit 002fc19

Please sign in to comment.