1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../general.ent">
8 <sect1 id="ch-system-linux-headers" role="wrap">
9 <?dbhtml filename="linux-headers.html"?>
11 <sect1info condition="script">
12 <productname>linux</productname>
13 <productnumber>&linux-version;</productnumber>
14 <address>&linux-url;</address>
17 <title>Linux-&linux-version; API Headers</title>
19 <indexterm zone="ch-system-linux-headers">
20 <primary sortas="a-Linux">Linux</primary>
21 <secondary>API headers</secondary>
24 <sect2 role="package">
27 <para>The Linux API Headers (in linux-&linux-version;.tar.xz) expose the
28 kernel's API for use by Glibc.</para>
31 <segtitle>&buildtime;</segtitle>
32 <segtitle>&diskspace;</segtitle>
35 <seg>&linux-headers-ch6-sbu;</seg>
36 <seg>&linux-headers-ch6-du;</seg>
42 <sect2 role="installation">
43 <title>Installation of Linux API Headers</title>
45 <para>The Linux kernel needs to expose an Application Programming Interface
46 (API) for the system's C library (Glibc in LFS) to use. This is done
47 by way of sanitizing various C header files that are shipped in the Linux
48 kernel source tarball.</para>
50 <para>Make sure there are no stale files and dependencies lying around
51 from previous activity:</para>
53 <screen><userinput remap="pre">make mrproper</userinput></screen>
55 <para>Now extract the user-visible kernel headers from the source.
56 They are placed in an intermediate local directory and copied to the needed
57 location because the extraction process removes any existing files in
58 the target directory. There are also some hidden files used by
59 the kernel developers and not needed by LFS that are removed from
60 the intermediate directory.</para>
62 <screen><userinput remap="make">make INSTALL_HDR_PATH=dest headers_install
63 find dest/include \( -name .install -o -name ..install.cmd \) -delete
64 </userinput><userinput remap="install">cp -rv dest/include/* /usr/include</userinput></screen>
68 <sect2 id="contents-linux-headers" role="content">
69 <title>Contents of Linux API Headers</title>
72 <segtitle>Installed headers</segtitle>
73 <segtitle>Installed directories</segtitle>
76 <seg>/usr/include/asm/*.h, /usr/include/asm-generic/*.h,
77 /usr/include/drm/*.h, /usr/include/linux/*.h, /usr/include/mtd/*.h,
78 /usr/include/rdma/*.h, /usr/include/scsi/*.h, /usr/include/sound/*.h,
79 /usr/include/video/*.h, and /usr/include/xen/*.h</seg>
80 <seg>/usr/include/asm, /usr/include/asm-generic, /usr/include/drm,
81 /usr/include/linux, /usr/include/mtd, /usr/include/rdma,
82 /usr/include/scsi, /usr/include/sound, /usr/include/video, and /usr/include/xen</seg>
87 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
88 <?dbfo list-presentation="list"?>
89 <?dbhtml list-presentation="table"?>
91 <varlistentry id="asm">
92 <term><filename class="headerfile">/usr/include/asm/*.h</filename></term>
94 <para>The Linux API ASM Headers</para>
95 <indexterm zone="ch-system-linux-headers asm">
96 <primary sortas="e-/usr/include/asm/*.h">/usr/include/asm/*.h</primary>
101 <varlistentry id="asm-generic">
102 <term><filename class="headerfile">/usr/include/asm-generic/*.h</filename></term>
104 <para>The Linux API ASM Generic Headers</para>
105 <indexterm zone="ch-system-linux-headers asm-generic">
106 <primary sortas="e-/usr/include/asm-generic/*.h">/usr/include/asm-generic/*.h</primary>
111 <varlistentry id="drm">
112 <term><filename class="headerfile">/usr/include/drm/*.h</filename></term>
114 <para>The Linux API DRM Headers</para>
115 <indexterm zone="ch-system-linux-headers drm">
116 <primary sortas="e-/usr/include/drm/*.h">/usr/include/drm/*.h</primary>
121 <varlistentry id="linux">
122 <term><filename class="headerfile">/usr/include/linux/*.h</filename></term>
124 <para>The Linux API Linux Headers</para>
125 <indexterm zone="ch-system-linux-headers linux">
126 <primary sortas="e-/usr/include/linux/*.h">/usr/include/linux/*.h</primary>
131 <varlistentry id="mtd">
132 <term><filename class="headerfile">/usr/include/mtd/*.h</filename></term>
134 <para>The Linux API MTD Headers</para>
135 <indexterm zone="ch-system-linux-headers mtd">
136 <primary sortas="e-/usr/include/mtd/*.h">/usr/include/mtd/*.h</primary>
141 <varlistentry id="rdma">
142 <term><filename class="headerfile">/usr/include/rdma/*.h</filename></term>
144 <para>The Linux API RDMA Headers</para>
145 <indexterm zone="ch-system-linux-headers rdma">
146 <primary sortas="e-/usr/include/rdma/*.h">/usr/include/rdma/*.h</primary>
151 <varlistentry id="scsi">
152 <term><filename class="headerfile">/usr/include/scsi/*.h</filename></term>
154 <para>The Linux API SCSI Headers</para>
155 <indexterm zone="ch-system-linux-headers scsi">
156 <primary sortas="e-/usr/include/scsi/*.h">/usr/include/scsi/*.h</primary>
161 <varlistentry id="sound">
162 <term><filename class="headerfile">/usr/include/sound/*.h</filename></term>
164 <para>The Linux API Sound Headers</para>
165 <indexterm zone="ch-system-linux-headers sound">
166 <primary sortas="e-/usr/include/sound/*.h">/usr/include/sound/*.h</primary>
171 <varlistentry id="video">
172 <term><filename class="headerfile">/usr/include/video/*.h</filename></term>
174 <para>The Linux API Video Headers</para>
175 <indexterm zone="ch-system-linux-headers video">
176 <primary sortas="e-/usr/include/video/*.h">/usr/include/video/*.h</primary>
181 <varlistentry id="xen">
182 <term><filename class="headerfile">/usr/include/xen/*.h</filename></term>
184 <para>The Linux API Xen Headers</para>
185 <indexterm zone="ch-system-linux-headers xen">
186 <primary sortas="e-/usr/include/xen/*.h">/usr/include/xen/*.h</primary>