Differences between revisions 5 and 6
Revision 5 as of 2012-10-19 10:16:19
Size: 2359
Editor: ?LisaMaginnis
Comment: formatting error
Revision 6 as of 2012-10-19 10:18:58
Size: 2363
Editor: ?LisaMaginnis
Comment: formatting error
Deletions are marked like this. Additions are marked like this.
Line 28: Line 28:
 {{{# The maintainer information.  {{{
# The maintainer information.
Line 30: Line 31:
email := unknown@unconfigured.in.etc.kernel-pkg.conf}}} email := unknown@unconfigured.in.etc.kernel-pkg.conf
}}}

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:

  • build-essential - Essential packages required for compiling.
  • linux-source - The Linux Kernel Source
  • kernel-package - Provides make-kpkg which we will use to build a Debian Kernel package.
  • libncurses5-dev - Development files for ncurses5. This alows for a curses based menu driven configuration.

To install these packages run the following command as root:

  • apt-get install build-essential linux-source kernel-package

Configuring Kernel-Package

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

  • emacs -nw /etc/kernel-pkg.conf

Navigate to this section of the configuration file:

  • # The maintainer information.
    maintainer := Unknown Kernel Package Maintainer
    email := unknown@unconfigured.in.etc.kernel-pkg.conf

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

Extracting the Kernel Source

As root, change directories to /usr/src:

  • cd /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):

  • tar xjvf linux-source-3.2.tar.bz2

Configuring the Kernel

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

  • cd linux-source-3.2

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

  • make ARCH=i386 defconfig

Building the Debian Package

Use make-kpkg to build the kernel:

  • {make-kpkg


CategoryKernel