linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* make modules_prepare failing
@ 2021-06-16 19:35 Tim Harvey
  2021-06-16 19:55 ` Russell King (Oracle)
  0 siblings, 1 reply; 4+ messages in thread
From: Tim Harvey @ 2021-06-16 19:35 UTC (permalink / raw)
  To: Linux ARM Mailing List

Greetings,

I'm trying to understand how to use the 'modules_prepare' target to
prepare kernel headers on a dev host appropriate for building
out-of-tree modules on a target board. I'm interested in the minimum
headers necessary and have noticed the Ubuntu 'linux-headers-*'
packages are only about 24MiB.

I've looked over
https://www.kernel.org/doc/Documentation/kbuild/modules.txt and it
does not provide an example showing how to build the headers in a
different directory.

$ make O=foo modules_prepare
make[1]: Entering directory '/usr/src/venice/bsp/linux/foo'
***
*** The source tree is not clean, please run 'make mrproper'
*** in /usr/src/venice/bsp/linux
***
/usr/src/venice/bsp/linux/Makefile:512: recipe for target
'outputmakefile' failed
make[1]: *** [outputmakefile] Error 1
make[1]: Leaving directory '/usr/src/venice/bsp/linux/foo'
Makefile:179: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2

A 'make mrproper' as suggested just complains that a .config is not
found, but then if there is a .config found it will complain I need to
make mrproper again.

The 'modules_prepare' does work if I don't try to output to a
different directory but then it isn't clear what to package compared
to the entire >1GiB kernel source tree.

I wish https://www.kernel.org/doc/Documentation/kbuild/modules.txt had
an example expalining how a distro packager would create
linux-headers-<foo>. I'm not familiar enough with Ubuntu packaging to
understand how to disect how their packages are created.

Any suggestions?

Best regards,

Tim

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-06-16 20:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-16 19:35 make modules_prepare failing Tim Harvey
2021-06-16 19:55 ` Russell King (Oracle)
2021-06-16 20:21   ` Tim Harvey
2021-06-16 20:37     ` Russell King (Oracle)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).