[oclug] kernel compile question
bart-oclug at jukie.net
Fri Aug 30 08:31:03 EDT 2002
> On Thu, 29 Aug 2002, Raj wrote:
> > I was just wondering how to compile a kernel for a different machine - my
> > laptop is a p120 and it takes forever to go through a cycle. How would I
> > go about compiling the kernel on my desktop and transferring it to the
> > laptop once done? I guess I could set the processor type and compile
> > it, but then what exactly would i have to transfer to the laptop and
> > how would i go about installing the kernel and modules on the laptop?
> > Also, the desktop has a custom kernel that I've compiled on it, I dont'
> > want to mess that up either!
I must have missed this question the first time around.
Here are my steps for doing what you have described.
First my tree:
/somewhere/linux - the tree I am compiling
/somewhere/dest - where I will store the binaries
Now the steps:
cp ../config-2.4.19 .config
make bzImage && make modules
mkdir -p ../dest/boot
cp arch/i386/boot/bzImage ../dest/boot/vmlinuz-2.4.20
cp System.map ../dest/boot/System.map-2.4.20
make INSTALL_MOD_PATH=/somewhere/dest modules_install
The variable INSTALL_MOD_PATH redirects all modules from dest into
/somewhere/dest/lib/modules/2.4.20/, which is what we want.
Note that there is a makefile variable INSTALL_PATH which should do the
same thing for `make install` but it had not worked for me. It should
be set to '/somewhere/dest/boot' if you want to try.
Anyway, once that is done I just rsync the files across to my 486,
re-run lilo, and in 30 minutes I am done what would have taken a day
to compile on the 486 itself. :)
If you don't want to use rsync you can just tar up the whole dest
directory and scp (or whatever) the file across.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
Url : http://tux.oclug.on.ca/pipermail/oclug/attachments/20020830/9b33cb11/attachment.bin
More information about the OCLUG