Kconfig in external modules
valdis.kletnieks at vt.edu
valdis.kletnieks at vt.edu
Thu Feb 22 08:37:08 EST 2018
On Thu, 22 Feb 2018 10:06:43 -0300, Gustavo Leite said:
> when I run the usual command to build external module
>
> $ make -C /lib/modules/`uname -r`/build M=/path/to/module modules
>
> the options present in the local .config file would be exported by kbuild as C
> #define's and make variables to be used in the module. The build system supports
> such feature?
This is probably a Bad Idea, because it results in a module that was built against
a different .config than the kernel it is loaded into. All sorts of things can go
wrong (for instance, consider if your local Kconfig did a 'select' to turn on
a CONFIG_ variable that wasn't on in the main kernel config).
You should just get the module fixed so it can be upstreamed and in-tree rather
than live life as an external module (plus, if you do that, you no longer need to
do all the updating of code when in-kernel API's change ;)
If you need config options for a module,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 486 bytes
Desc: not available
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180222/9c502417/attachment.sig>
More information about the Kernelnewbies
mailing list