LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   compiling a kernel somewhere other than /usr/src (https://www.linuxquestions.org/questions/linux-newbie-8/compiling-a-kernel-somewhere-other-than-usr-src-90172/)

h/w 09-07-2003 10:31 AM

compiling a kernel somewhere other than /usr/src
 
hi - i have a doubt.
most documents talk about compiling the kernel under /usr/src. then compiling the modules under /usr/src where the kernel is built.

if i build the kernel in some other place, for instance, /home, and have a sym link in /usr/src, to the /home dir where the kernel source is, where should i be compiling the modules? should i do it under /usr/src OR /home - where the source is?

thank you once again for the invaluable help. :)

Hangdog42 09-07-2003 10:36 AM

Although I'm not kernel expert, I would think you would be doing all your compiling in the /home directory where you've actually got the source files. I think that the kernel or modules don't care where they are compiled, rather the /usr/src is a convention so that other things (like video drivers) that need the kernel configuration and source know where to look. In which case, you should have it covered with your link.

h/w 09-07-2003 10:40 AM

umm, so you say that i should do it in the '/home' dir then?
i havent ever compiled the pcmcia modules yet, so i just wanted to be sure b4 i started.
ok, so apart from the "linux" symlink in '/usr/src' , are there any other links i should create if i have to install the pcmcia-source, and compile them?

thanks a million.

Hangdog42 09-07-2003 05:18 PM

I think compiling in the /home should work. The bit you'll have to pay attention to is installing the kernel and modules to the right places once the compiling is done.

And just to be safe, be sure you have a backup kernel. Before I started compiling kernels, I copied my existing kernel to vmlinuz.good and my System.map to System.good and made a new entry for them in in lilo. That way, no matter how badly I screw up a kernel compile, I've got a good kernel ready to roll.

h/w 09-07-2003 06:34 PM

right.


All times are GMT -5. The time now is 06:08 PM.