[OE-core] [PATCH 1/1] kernel: restore scripts in the sysroot

Phil Blundell pb at pbcl.net
Tue Nov 19 23:41:41 UTC 2013


On Tue, 2013-11-19 at 14:29 -0800, Khem Raj wrote:
> Well reproducer case is that build from sstate but such that an external module needs to be rebuilt
> if external module also comes from sstate then it all is fine. Its only when everything is coming from
> sstate except this external module which needs to be rebuilt then you see this problem.
> 
> now, I see the code in module-base.class
> 
> #
> # Ensure the hostprogs are available for module compilation. Modules that
> # inherit this recipe and override do_compile() should be sure to call
> # do_make_scripts() or ensure the scripts are built independently.
> #
> do_make_scripts() {
>         unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS 
>         make CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
>                    -C ${STAGING_KERNEL_DIR} scripts
> }
> 
> so it expects that, do_make_scripts is explicitly called by external module recipes
> 
> and my recipes did override module_do_compile task but not do_compile like below
> 
> module_do_compile() {
>         oe_runmake
> }
> 
> so, is comment wrong there should it say module_do_compile instead ?

The comment is slightly wrong, yes.  For correct results you need to
either:

1. inherit module (not module-base), which does:

addtask make_scripts after do_patch before do_compile

and will ensure that the scripts are built before your module is
compiled without you needing to do anything else.  Or...

2. inherit module-base and arrange to call do_make_scripts() explicitly
from your own recipe.

p.





More information about the Openembedded-core mailing list