kernel-source vs. kernel-sourcecode (please revert)

Axel Thimm Axel.Thimm at ATrpms.net
Tue Jun 15 11:29:34 UTC 2004


On Tue, Jun 15, 2004 at 01:14:20PM +0200, Arjan van de Ven wrote:
> > On Tue, Jun 15, 2004 at 12:16:50PM +0200, Arjan van de Ven wrote:
> > > > There are probably lots of
> > > > auto-build-some-3rd-party-kernel-module.sh scripts that do sanity
> > > > checking and will now break.
> > > 
> > > those scripts then are very broken even in FC2 GA since you cannot
> > > use kernel-source for building kernel modules in FC2.
> > > (well not for modules against the currently running kernel, of
> > > course you can build your own kernel with kernel source and then you
> > > can use it to build modules against that kernel).
> > 
> > There are O(1000) kernel module rpms build upon that. The bugs in the
> > kernel-source rpm prohibiting building against it are well known and
> > dealt with:
> 
> these are ALL wrong then with the 2.6 kernel and with the 2.6 rpms. Really.
> Removing custom and all those hacks are *WRONG*. Even on 2.4.
> Any kernel module that does that is *BROKEN* build wise. Extremely broken.

Practice says otherwise. kernel module rpms for 2.4 and 2.6 are out
there and are in use by several thousands of users without any
problems regarding kernel infrastructure.

> You build your module against /lib/modules/`uname -r`/build.

Not if you build against not-running or even not-installed kernels.

> Even in the 2.4 rpms you SHOULD NOT touch files in /usr/src/anything
> to build an external module. If you do you prevent later builds of
> more correct modules to work.

Sensible scripts do not modify /usr/src/linux-*, even though it's
broken, but copy it's contents to a temporary folder before removing
the child safety pins.

> The kernel-doc documentation explains it for 2.6,
> if your module is called foo.c you make a Makefile with
> obj-m := foo.o
> in it, and do
> make -C /lib/modules/`uname -r`/build SUBDIRS=$PWD modules
> to build your module.

SUBDIRS in 2.6.x is deprecated, but a good compatibility bridge to
save over 2.4.x kernel modules. Still, it is not quaranteed that there
will be a matching kernel installed or even running.

> In FC2 that uses ZERO files from kernel-source (unlike FC1 where that was a
> symlink into kernel-source).
> Any other method WILL eventually result in non-working modules.

They do work.

You need to be able to build for non-running and non-installed kernel,
at least this is true for bigger repos, that build for multiple
kernels per distro and for multiple distros. For instance ATrpms
builds kernel modules for 6 different distributions for 4-12 kernel
per distribution. Similar statements are true for other
repos. Obviously I cannot have that many machines running the kernel
to build against. One machine per arch familiy is enough.

Anyway this does drift away from the real issue, which is the renaming
of kernel-source. Obviouls "kernel-source" is successfully used at
many places (40000+ hits for Red Hat/Fedora relevant pages in
google). Could you please revert that, and have it fixed in yum
instead?
-- 
Axel.Thimm at ATrpms.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/fedora-devel-list/attachments/20040615/b644e3a2/attachment.sig>


More information about the fedora-devel-list mailing list