1. download the latest FULL source from www.kernel.org (I don't mess with the debs personally, I want the latest that kernel.org has to offer). save the source .tar.bz2 (or tar.gz) to /usr/src.
  2. decompress and untar the image in /usr/src. For example if you downloaded linux-2.6.3.tar.bz2 when uncompressed you should have a folder for /usr/src/linux/linux-2.6.3
  3. there's a few packages we'll need to install before compiling the kernelt:
    Code:
    apt-get install kernel-package libncurses5-dev
    (and if building a 2.6.x kernel for the first time you'll want to add module-init-tools to this list as well)
  4. in /usr/src/linux-2.6.3/ run the following commands
    Code:
    make mrproper
    make menuconfig
    mrproper will insure a clean build and import some settings from your current working kernel. make menuconfig is an ncurses menu where you can go through and unselect/select support for various hardware and such relating to your computer. Once inside menuconfig the commands for adding/removing support are as follows: Y=yes (built-in support) N=no (no support) M=compiles support as a module. When you exit menuconfig say "yes" to saving the changes.

    {*] now that you've trimmed the fat from the kernel we're ready to build it as a package. in /usr/src/linux-2.6.3 run the following commands (as root):

    Code:
    su
    Password:
    make-kpkg clean
    make-kpkg kernel_image
  5. go make lunch, have a cup of coffee, pop in a movie, whatever, the compiling of the kernel into an installable .deb ipackage will take a while. Assuming the .deb was created with no fatal errors you'll now have a kernel package in /usr/src . now we need to install it, in /usr/src/ run the follwing command (still as root)

    Code:
    dpkg -i kernel-image-2.6.3_10.00.Custom_i386.deb
  6. for some reason /etc/lilo.conf is never updated correctly to add an entry for the new kernel, so we must edit it manually (still as root). Add the following entry to the very bottom of /etc/lilo.conf:

    Code:
    image=/boot/vmlinuz-2.6.3
            label=2.6.3
            initrd=/boot/linux-2.6.1.gz
            read-only
            #       restricted
    basically you want to clone the existing entry in lilo.conf for your working kernel, and replace the image= line with the vmlinuz image created in /boot when you installed the kernel_image.deb. your initrd image you want to keep the same as your working kernel (or comment it out if you disabled intial ramdisk support in the kernel you compiled). label= iyou can set to say whatever you want to indicate on the lilo boot menu what kernel you'll be booting into (you will want to make sure the prompt line in /etc/lilo conf is not commented out)
  7. all we need to do now is update lilo.
    Code:
    /sbin/lilo -v
  8. reboot your computer, and in your lilo menu you should now have an entry at the bottom for this new kernel, select it, and if all went well you'll be up and running with your new custom kernel, nto bogged down by all the modules loaded by defualt in a typical knoppix install.
  9. As a footnote if you're compiling ALSA into your kernel for the first time you'll also want to install the following packages:

    Code:
    apt-get install alsa-base alsa-utils gnome-alsamixer
    upon installation fo these you'll be asked which soundcard(s) you want to install sound support for.. gnome-alsamixer is a nice gui tool for the inital umuting you need to do once ALSA is installed.