* this way we can reuse the same functionality also for external modules including module_autoload_foo and module_conf_foo functionality * MODULE_PACKAGES variable was removed (splited modules are now returned by do_split_packages * KERNEL_MODULES_META_PACKAGE is used to append all splitted packages to RDEPENDS. In kernel.bbclass it's old "kernel-modules" in module.bbclass it defaults to ${PN} for upgrade path from single PN with all modules to PN depending on all new kernel-module-* (From OE-Core rev: 51928b6b5ca0a46a9dcd754483a19af58b95fa18) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
33 lines
947 B
Text
33 lines
947 B
Text
DEPENDS += "virtual/kernel"
|
|
|
|
inherit module-base kernel-module-split
|
|
|
|
addtask make_scripts after do_patch before do_compile
|
|
do_make_scripts[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
|
|
do_make_scripts[deptask] = "do_populate_sysroot"
|
|
|
|
module_do_compile() {
|
|
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
|
|
oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \
|
|
KERNEL_SRC=${STAGING_KERNEL_DIR} \
|
|
KERNEL_VERSION=${KERNEL_VERSION} \
|
|
CC="${KERNEL_CC}" LD="${KERNEL_LD}" \
|
|
AR="${KERNEL_AR}" \
|
|
${MAKE_TARGETS}
|
|
}
|
|
|
|
module_do_install() {
|
|
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
|
|
oe_runmake DEPMOD=echo INSTALL_MOD_PATH="${D}" \
|
|
KERNEL_SRC=${STAGING_KERNEL_DIR} \
|
|
CC="${KERNEL_CC}" LD="${KERNEL_LD}" \
|
|
modules_install
|
|
}
|
|
|
|
EXPORT_FUNCTIONS do_compile do_install
|
|
|
|
# add all splitted modules to PN RDEPENDS, PN can be empty now
|
|
KERNEL_MODULES_META_PACKAGE = "${PN}"
|
|
FILES_${PN} = ""
|
|
ALLOW_EMPTY_${PN} = "1"
|