Today's operating systems are built in "layers". Each layer has different functions such as serial port access, disk access, and the user interface itself. The base layer, or the foundation of the operating system, is called a kernel. The kernel provides low-level services, such as the hardware-software interaction and memory management -- much like a kernel of corn. Or not.
The Linux Kernel Archives
Latest Version (rss)
The Linux Kernel HOWTO
Reasons to self-compile
You may compile Linux kernel for one of following reasons:
- You are doing kernel development
- You are adding a new hardware to machine
- You want to customize the kernel and do not want the default kernel shipped out to you.
- For Defence Industries or Military applications, you must read the kernel source code and compile with your own hands. No exceptions!! (U.S Dept of Defence compiles the Linux kernel before distributing computers).
- Every country and every Govt. compiles the kernel on site for security. Every Govt. audits each and every line of kernel before using the computer.
- Each and every University in the world compiles the kernel before using any computer!
- For your education and knowledge of Linux kernel and ofcourse, just for fun!
- For very advanced scientific applications - you may need to do kernel compile
- And for many hundreds of reasons - too numerous to list!
For the Impatient
- Unpack the sources
- Optional - You can copy the .config file from your old linux kernel source tree to new kernel tree (may save time, if you want to reuse the old settings).
- make clean; make mrproper
- make xconfig
- make dep
- make bzImage
- make modules
- make install
- make modules_install
- configure LILO or GRUB.
- Optional - make clean (If you want to free up disk space)
Smaller Kernel size
The kernel source is HUUUUGE and takes too long to download. Couldn't it be split in various tarballs?
(REG) The kernel (as of 2.1.110) has about 1.5 million lines of code in *.c, *.h and *.S files. Of those, about 253 k lines (17%) are in the architecture-specific subdirectories, and about 815 k lines (54%) are in platform-independent drivers. If, like most people, you are only interested in i386, you could save about 230 k lines by removing the other architecture-specific trees. That is a 15% saving, which is not that much, really. The "core" kernel and filesystems take up about 433 k lines, or around 29%. ... Throwing out the non i386-specific drivers will save around 97 k lines, a saving of about 6%. ...
from the Linux Kernel Mailing List FAQ