Debian Kernel Compiler / Packager
make-kpkg - build Debian kernel packages from Linux kernel sources
This utility needs to be run from a top level Linux kernel source directory,
which has been previously configured (/usr/src/linux).
make-kpkg --append_to_version foo
This argument ( foo ) is appended to the value of the EXTRAVERSION variable
present in the kernel Makefile. Since EXTRAVERSION is a component of the kernel
version, it is also added to the Debian package name, and, as such must obey the
policy governing the package name. That means it may contain only lowercase
alphanumerics and the characters - + . (full stop, hyphen, and plus).
Note also that once you use --append_to_version foo for configuring, or building
the kernel-image, you need to also use the same option in any later invocation
of make-kpkg (say, for building stand alone modules, or something). make-kpkg
does not remember the argument foo in between invocations (this is different
from the behavior of --revision, which we do remember in between invocations).
make-kpkg --revision='1.2.3'
Changes the Debian revision number for the packages produced to the argument
number. The version may contain only alphanumerics and the characters + .
(full stop and plus) and must contain a digit.
--arch foo
This is useful for setting the architecture when you are cross compiling.
If you are not cross compiling, the architecture is determined automatically.
The same effect can be achieved by setting the environment variable KPKG_ARCH
--cross_compile foo
This is useful for setting the target string when you are cross compiling.
The same effect can be achieved by setting the environment variable
CROSS_COMPILE.
--noexec
Pass a -n option to the make process so that commands are merely printed to the
screen but not actually executed. This is very useful for debugging.
kernel_headers
This target produces a Debian package containing the header files included
in the Linux kernel.
kernel_image
This target produces a Debian package of the Linux kernel source image, and
any modules configured in the kernel configuration file .config.
modules_image
This target allows you to build all packages under MODULE_LOC, which defaults
to /usr/src/modules, but does not create the source or diff files, and does not
create and sign a changes file. This is the only modules related option you need
if you just want to compile the add on modules image files for installation on
one or more machines. Generally called in conjunction with kernel_image,
especially if also using the option append_to_version (prevents spurious
warnings).