Skip to contentSkip to conversation

module_strip.bbclass and get_kernelmajorversion

DISCUSSION pieterg 1 participant 1 message Sep 29, 2010

lore
Share & tools
lore

pieterg

author
#0 lore raw

recipes inheriting 'module' are triggering this error:

NOTE: <type 'exceptions.NameError'>:name 'get_kernelmajorversion' is not defined while evaluating:

	if test -e ${PKGD}/lib/modules; then
		if [ "${KERNEL_MAJOR_VERSION}" == "2.6" ]; then

This is because module.bbclass inherits module-base, which inherits module_strip.
And module_strip uses get_kernelmajorversion, which is defined by linux-kernel-base.bbclass.
So as long as both module_strip and linux-kernel-base are both inherited, like kernel.bbclass does, everything is fine.
But with module.bbclass, get_kernelmajorversion is missing.

Should module_strip.bbclass inherit linux-kernel-base? Or is there a better fix?

Rgds, Pieter