Linux Kernel Compilation Guide for Ubuntu users

by
I have been trying to compile the kernel for the past few days and get everything in order. Now that I have everything in order, I thought of putting up this post. I am basically putting up various links to guides that I used ( will save you a lot of searching).

  1. Packages

You can use the vanilla kernel from kernel.org or install the linux-source package from the Ubuntu repository. I used the latter as it also has the Ubuntu specific patches.

For the compilation process this guide is the best.

  • ALSA

After compile you will find that the sound on your compiled kernel does not work and the nvidia ( or ATI ) drivers are also not detected. To make this right just follow the guides below::

For alsa drivers, install the alsa-source package extract the archive and then give the following commands as root.

# ./configure --with-kernel=dir #where dir = your kernel source directory
# make
# make install-modules

If for some reason this fails, check these pages.

ALSA wiki

Other guide

  • nVidia

Getting the nvidia drivers working in the compiled kernel was a royal pain for me. May be I was googling for the wrong things. Anyways, I finally found the answer. Just follow this guide and you will have the nvidia drivers installed and running on your compiled kernel just fine.

  • ATI

I was also able to get this guide for installing ATI drivers from source. Don’t know if this works or not. If anyone does try it, please comment about its validity.

EDIT :: It looks like master_kernel at ubuntuforums thought that his thread was not enough. He has made a GUI app which follows the steps in the thread and does everything for you. All though I still prefer the CLI way I thought this was a good thing for very new users. Plus it installs the nvidia and ati drivers all by itself. Go here for more info.

A few screenshots follow::

Happy compiling.

Advertisements

Tags:

2 Responses to “Linux Kernel Compilation Guide for Ubuntu users”

  1. Aniket Zamwar Says:

    i think this will help me…
    i needed it..
    also put sum post on hw to write Kernel modules..

  2. - Amod Says:

    hmmm…

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: