Translation(s): none

This is a guide on how to build the Linux Kernel with make-kpkg.

Install the Required Packages

To download and compile the Linux Kernel source we will need the following packages:

To install these packages run the following command as root:

Configuring Kernel-Package

As root, using the editor of your choice open /etc/kernel-pkg.conf, in this example we will be using emacs.

Navigate to this section of the configuration file:

Update the maintainer and email fields, then save and quit.

Extracting the Kernel Source

As root, change directories to /usr/src:

Here you will find a file looking like linux-source-x.x.tar.bz2. Please note that x.x will match the current Linux Kernel source for your release of Debian. In this example we will be using the 3.2 Kernel under Sid.

Extract the Kernel Source with the following command (NOTE: You will need to change 3.2 to match the .tar.bz2 file in /usr/src):

Configuring the Kernel

Change directories to the newly extracted linux source (again, match 3.2 to your version):

Create a defconfig with the following command, please change ARCH=i386 to match your target architecture:

Building the Debian Package

Use make-kpkg to build the kernel:

See also

The "Compiling a Kernel" section in the Debian Administrator's Guide