[yocto] building external modules

Pierre Yves MORDRET pierre-yves.mordret at st.com
Tue Aug 25 09:27:06 PDT 2015


Hello,

I have a sporadic compilation issue for a while and I never found out so far where it came from until now (perhaps). 
I mean by sporadic that it happens "sometimes" (2% of a time) 
I'm using daisy branch and the build failure happens in a Kernel External. It ends up like this:

DEBUG: Executing shell function do_compile
NOTE: make -j 24 -e ...  -C <sysroot>/usr/src/kernel O=<sysroot>/usr/src/kernel KBUILD_VERBOSE=1 M=<external_mod_path> ... modules
   [...]
   arm-rdk-linux-gnueabi-ld -EL    -r -o <object>.o [...] ; scripts/mod/modpost <object>.o
  /bin/sh: scripts/mod/modpost: Permission denied

Looking at logs and bbclass, I've seen a "make scripts"(module.bbclass/do_make_scripts) is issued anytime we build a Kernel External module.
Even if there is a "lock" mechanism to prevent race condition during this "do_make_scripts", nothing prevent to call "do_make_scripts" from a Ext Mod 1 during a "do_compile" from a Ext Mod 2.

I think (but not sure) this is another race condition here.
Do I miss something ?

Thanks in advance



More information about the yocto mailing list