external modules documentation
Subsystems (2)
Sam,
is there any reason your patch from June still isn't merged?
# This is a BitKeeper generated diff -Nru style patch. #
# ChangeSet
# 2004/06/14 22:21:46+02:00 [email protected]
# kbuild: Add external module documentation
#
# Add first version of a document describing how to build external modules. # This is not yet finished, but includes information that is nice to have # documented in the kernel even in a less complete form.
#
# Signed-off-by: Sam Ravnborg <[email protected]>
#
# Documentation/kbuild/extmodules.txt
# 2004/06/14 22:21:32+02:00 [email protected] +168 -0
#
# Documentation/kbuild/extmodules.txt
# 2004/06/14 22:21:32+02:00 [email protected] +0 -0
# BitKeeper file /home/sam/bk/kbuild/Documentation/kbuild/extmodules.txt
#
# Documentation/kbuild/00-INDEX
# 2004/06/14 22:21:32+02:00 [email protected] +2 -0
# Added extmodules.txt
#
Documentation/kbuild/00-INDEX +2 -0
@@ -6,3 +6,5 @@ - developer information for linux kernel makefiles modules.txt - how to build modules and to install them +extmodules.txt + - specific information about external modules
Documentation/kbuild/extmodules.txt new file +168 -0
168 lines not on this page · raw message
Quoted 4 lines · Christoph Hellwig
Sam,
is there any reason your patch from June still isn't merged?
[...]
Documentation/kbuild/extmodules.txt line 151
Quoted 12 lines
Documentation/kbuild/extmodules.txt new file +12
-0+Prepare the kernel for building external modules +------------------------------------------------ +When building external modules the kernel is expected to be prepared. +This includes the precense of certain binaries, the kernel configuration +and the symlink to include/asm. +To do this a convinient target is made: + + make modules_prepare + +For a typical distribution this would look like the follwoing: + + make modules_prepare O=/lib/modules/linux-<kernel version>/build
Tthis means that one, unmodified source tree is _not_ usable for multiple architectures. You can't use the same, prepared sources and for example create noarch.rpm or burn on cd and then use for external modules building on different architectures.
We are using this:
http://cvs.pld-linux.org/cgi-bin/cvsweb/SOURCES/linux-kbuild-extmod.patch?rev=1.2
to get external modules working for multiple archs with the same sources:
http://cvs.pld-linux.org/cgi-bin/cvsweb/SPECS/template-kernel-module.spec?rev=1.14
Signature · 2 lines
Arkadiusz Miśkiewicz PLD/Linux Team http://www.t17.ds.pwr.wroc.pl/~misiek/ http://ftp.pld-linux.org/
Quoted 3 lines · Christoph Hellwig
Sam,
is there any reason your patch from June still isn't merged?
It need a few hours update and I have been to spoiled to do it. Will look at it pretty soon - thanks for reminder.
Sam
Quoted 6 lines · Arkadiusz Miskiewicz
Quoted 4 lines · Christoph Hellwig
Sam,
is there any reason your patch from June still isn't merged?
[...]
Quoted 16 lines
Documentation/kbuild/extmodules.txt line 151
Quoted 12 lines
Documentation/kbuild/extmodules.txt new file +12
-0+Prepare the kernel for building external modules +------------------------------------------------ +When building external modules the kernel is expected to be prepared. +This includes the precense of certain binaries, the kernel configuration +and the symlink to include/asm. +To do this a convinient target is made: + + make modules_prepare + +For a typical distribution this would look like the follwoing: + + make modules_prepare O=/lib/modules/linux-<kernel version>/buildTthis means that one, unmodified source tree is _not_ usable for multiple architectures. You can't use the same, prepared sources and for example create noarch.rpm or burn on cd and then use for external modules building on different architectures.
You are doing it wrong.
You need in your case one source tree, several output dirs. So use
make ARCH=sparc CROSS_COMPILE=xxx O=~/build/sparc ...
make ARCH=ppc CROSS_COMPILE=xxx O=~/build/ppc ...
The patch below is flawed.
Quoted 5 lines
We are using this:
http://cvs.pld-linux.org/cgi-bin/cvsweb/SOURCES/linux-kbuild-extmod.patch?rev=1.2
to get external modules working for multiple archs with the same sources:
http://cvs.pld-linux.org/cgi-bin/cvsweb/SPECS/template-kernel-module.spec?rev=1.14
Sam
Quoted 11 lines · Sam Ravnborg
Quoted 4 lines
Tthis means that one, unmodified source tree is _not_ usable for multiple architectures. You can't use the same, prepared sources and for example create noarch.rpm or burn on cd and then use for external modules building on different architectures.
You are doing it wrong.
You need in your case one source tree, several output dirs. So use
make ARCH=sparc CROSS_COMPILE=xxx O=~/build/sparc ...make ARCH=ppc CROSS_COMPILE=xxx O=~/build/ppc ...
cross_compile? I don't want to make cross compilation. I want to use the same source on my x86 machine, ppc machine, alpha machine, sparc machine and so on. Since make in external modules dir doesn't create scripts and such kbuild stuff I don't see how this can work with make modules_prepare.
Please explain.
Quoted 1 line
Sam
Signature · 2 lines
Arkadiusz Miśkiewicz PLD/Linux Team http://www.t17.ds.pwr.wroc.pl/~misiek/ http://ftp.pld-linux.org/