View previous topic :: View next topic |
Author |
Message |
Cyberwizzard Apprentice
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Sat Aug 12, 2006 2:22 pm Post subject: [SOLVED] Compile modules for the Live CD kernel |
|
|
I decided to post my actual problem under a new topic (this one) hoping someone could help me then
I got the live disc kernel running on a machine and I'd like to compile some new modules for that kernel (2.6.15-r5 gentoo) but that specific version is no longer in the portage tree. Is there a way to use a r1 or different revision to compile the modules? I mean there can't be that many changes in the revisions that an external module (vmware) can't be compiled against it... right?
Last edited by Cyberwizzard on Sat Aug 12, 2006 10:39 pm; edited 1 time in total |
|
Back to top |
|
|
sfragis Tux's lil' helper
Joined: 24 Mar 2005 Posts: 95 Location: RE < IT < Europe
|
Posted: Sat Aug 12, 2006 4:11 pm Post subject: |
|
|
IMHO, one could use a different revision (such as r1 or r8, which are still in portage); a change in the revision number should reflect kernel bug fixes mainly. If you want to build the module with emerge, I think that /usr/src/linux must be a valid link to an existing kernel tree. Suppose you emerged gentoo-sources-2.6.15-r1. That will cause the module being installed in /lib/modules/2.6.15-r1/x/y/z.ko even if you booted with a different kernel (2.6.15-r5 in your case). You can try moving the module to the right directory /lib/modules/2.6.15-r5/x/y/z.ko. Maybe a "depmod -a" is also useful. _________________ Regards
Fabio Strozzi |
|
Back to top |
|
|
Cyberwizzard Apprentice
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Sat Aug 12, 2006 10:00 pm Post subject: |
|
|
So in theory I should be able to emerge vmware-modules (from the overlay) and grab the modules from the r1 or r8 module directory and depmod -a my way in there? Sounds good |
|
Back to top |
|
|
Cyberwizzard Apprentice
Joined: 02 Apr 2004 Posts: 244 Location: Norway
|
Posted: Sat Aug 12, 2006 10:38 pm Post subject: |
|
|
I'm logging here what I'm doing:
I just unmasked and emerged gentoo-sources-2.6.15-r8. Then I set /usr/src/linux to the r8 sources. Next I copied the System map file from /boot to the sources dir and renamed it to System.map.
Next I copied and decompressed /proc/config.gz to /usr/src/linux/.config
Next I ran 'make oldconfig' and 'make modules_prepare' to be able to run 'emerge vmware-modules'.
After emerging the modules I moved the misc directory in /lib/modules from the r8 to r5 and ran 'depmod -a'.
I entered 'modprobe vmmon' and 'modprobe vmnet' and behold... IT WORKED!
I tried something like this before but it failed time after time... This time I changed 3 things: used the r8 kernel, copied the System.map emerge complained about and ran 'depmod -a' to fix the dependencies (instead of forcing them in).
Thanks a lot! |
|
Back to top |
|
|
|