mirror of
https://git.yoctoproject.org/poky
synced 2026-02-08 09:46:38 +01:00
This allows the kernel-yocto bbclass to be inherited in a recipe without needing to include linux-yocto.inc. The bbclass should stand on its own and linux-yocto.inc does a few things which may not be desired in other kernel recipes (such as modifying KERNEL_FEATURES). The LINUX_VERSION_EXTENSION default is not moved as other kernel recipes may not want this setting in place. (From OE-Core rev: 48d8f97975c0b167c0f4f32145813f00b8c8a7a8) Signed-off-by: Paul Barker <pbarker@konsulko.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
58 lines
1.9 KiB
PHP
58 lines
1.9 KiB
PHP
SUMMARY = "Linux kernel"
|
|
SECTION = "kernel"
|
|
LICENSE = "GPLv2"
|
|
|
|
LIC_FILES_CHKSUM ?= "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
|
|
|
|
UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.\d+)*)"
|
|
|
|
INC_PR = "r4"
|
|
|
|
# Skip processing of this recipe if it is not explicitly specified as the
|
|
# PREFERRED_PROVIDER for virtual/kernel. This avoids network access required
|
|
# by the use of AUTOREV SRCREVs, which are the default for this recipe.
|
|
python () {
|
|
if d.getVar("KERNEL_PACKAGE_NAME") == "kernel" and d.getVar("PREFERRED_PROVIDER_virtual/kernel") != d.getVar("PN"):
|
|
d.delVar("BB_DONT_CACHE")
|
|
raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to %s to enable it" % (d.getVar("PN")))
|
|
}
|
|
|
|
DEPENDS += "xz-native bc-native"
|
|
DEPENDS_append_aarch64 = " libgcc"
|
|
KERNEL_CC_append_aarch64 = " ${TOOLCHAIN_OPTIONS}"
|
|
KERNEL_LD_append_aarch64 = " ${TOOLCHAIN_OPTIONS}"
|
|
|
|
DEPENDS_append_nios2 = " libgcc"
|
|
KERNEL_CC_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
|
|
KERNEL_LD_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
|
|
|
|
DEPENDS_append_arc = " libgcc"
|
|
KERNEL_CC_append_arc = " ${TOOLCHAIN_OPTIONS}"
|
|
KERNEL_LD_append_arc = " ${TOOLCHAIN_OPTIONS}"
|
|
|
|
KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc"
|
|
|
|
KERNEL_FEATURES_append = " ${@bb.utils.contains('MACHINE_FEATURES', 'numa', 'features/numa/numa.scc', '', d)}"
|
|
|
|
# A KMACHINE is the mapping of a yocto $MACHINE to what is built
|
|
# by the kernel. This is typically the branch that should be built,
|
|
# and it can be specific to the machine or shared
|
|
# KMACHINE = "UNDEFINED"
|
|
|
|
LINUX_VERSION_EXTENSION ??= "-yocto-${LINUX_KERNEL_TYPE}"
|
|
|
|
# Pick up shared functions
|
|
inherit kernel
|
|
inherit kernel-yocto
|
|
|
|
B = "${WORKDIR}/linux-${PACKAGE_ARCH}-${LINUX_KERNEL_TYPE}-build"
|
|
|
|
do_install_append(){
|
|
if [ -n "${KMETA}" ]; then
|
|
rm -rf ${STAGING_KERNEL_DIR}/${KMETA}
|
|
fi
|
|
}
|
|
|
|
# enable kernel-sample for oeqa/runtime/cases's ksample.py test
|
|
KERNEL_FEATURES_append_qemuall=" features/kernel-sample/kernel-sample.scc"
|