10.5. Linux-3.14.21 Headers

The Linux Kernel contains a make target that installs “sanitized” kernel headers.

10.5.1. Installation of Linux Headers

[Note]

Note

For this step you will need to unpack the kernel tarball (linux-3.14.tar.xz) and cd into its source directory before entering the commands on this page.

Apply the latest Linux sublevel patch:

xzcat ../patch-3.14.21.xz | patch -Np1 -i -

Install the kernel header files:

make mrproper
make headers_check
make INSTALL_HDR_PATH=/usr headers_install
find /usr/include -name .install -or -name ..install.cmd | xargs rm -fv

The meaning of the make commands:

make mrproper

Ensures that the kernel source dir is clean.

make headers_check

Sanitizes the raw kernel headers so that they can be used by userspace programs.

make INSTALL_HDR_PATH=/usr headers_install

This will install the kernel headers into /usr/include.

find /usr/include -name .install -or -name ..install.cmd | xargs rm -fv

Removes a number of unneeded debugging files that were installed.

10.5.2. Contents of Linux Headers

Installed headers: /usr/include/{asm,asm-generic,drm,linux,mtd,rdma,scsi,sound,video,xen}/*.h
Installed directories: /usr/include/asm, /usr/include/asm-generic, /usr/include/drm, /usr/include/linux, /usr/include/mtd, /usr/include/rdma, /usr/include/scsi, /usr/include/sound, /usr/include/uapi, /usr/include/video, /usr/include/xen

Short Descriptions

/usr/include/{asm,asm-generic,drm,linux,mtd,rdma,sound,video}/*.h

The Linux API headers