[OE-core] How to skip building kernel modules

Jacob Kroon jacob.kroon at gmail.com
Mon Mar 16 09:22:38 UTC 2020


On 3/16/20 10:12 AM, Alexander Kanavin wrote:
> The way I read kernel.bbclass, you need to set CONFIG_MODULES=n in your 
> configuration through some mechanism; then they'll be skipped altogether.
> 
> Alex
> 

Yeah, I should have mentioned, setting CONFIG_MODULES=n in a config 
fragment causes all modules to be built into the kernel, which is not 
what I want.

I've also tried setting

do_compile_kernelmodules[noexec] = "1"

but that breaks do_install()

/Jacob

> On Mon, 16 Mar 2020 at 10:06, Jacob Kroon <jacob.kroon at gmail.com 
> <mailto:jacob.kroon at gmail.com>> wrote:
> 
>     Hi,
> 
>     I'm using the linux-yocto kernel recipes together with additional
>     kernel
>     config fragments that I append in our custom distro layer. All required
>     functionality is built into the kernel, so we don't install any kernel
>     modules on target.
> 
>     What would be the correct way to save compilation time and skip
>     building/packaging the kernel modules ? Do I need to provide a custom
>     defconfig that explicitly disables all modules ?
> 
>     I can monkey-patch oe-core with the attached patch in order to achieve
>     that goal, but I'm guessing something like this wouldn't be suitable
>     for
>     upstreaming ?
> 
>     Cheers,
>     Jacob
> 
>     -- 
>     _______________________________________________
>     Openembedded-core mailing list
>     Openembedded-core at lists.openembedded.org
>     <mailto:Openembedded-core at lists.openembedded.org>
>     http://lists.openembedded.org/mailman/listinfo/openembedded-core
> 


More information about the Openembedded-core mailing list