source: BOOK/final-system/common/linux-headers.xml@ 480230bc

clfs-3.0.0-sysvinit sysvinit
Last change on this file since 480230bc was 8a9af10, checked in by Chris Staub <chris@…>, 10 years ago

Add command tag for make

  • Property mode set to 100644
File size: 4.0 KB
Line 
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">
5 %general-entities;
6]>
7
8<sect1 id="ch-system-linux-headers" role="wrap">
9 <?dbhtml filename="linux-headers.html"?>
10
11 <title>Linux-&linux-version2; Headers</title>
12
13 <indexterm zone="ch-system-linux-headers">
14 <primary sortas="a-Linux Headers">Linux Headers</primary>
15 </indexterm>
16
17 <sect2 role="package">
18 <title/>
19
20 <para>The Linux Kernel contains a <command>make</command> target that
21 installs <quote>sanitized</quote> kernel headers.</para>
22
23 </sect2>
24
25 <sect2 role="installation">
26 <title>Installation of Linux Headers</title>
27
28 <note os="a">
29 <para>For this step you will need to unpack the kernel tarball
30 (<filename>linux-&linux-version;.tar.xz</filename>) and
31 <command>cd</command> into its source
32 directory before entering the commands on this page.</para>
33 </note>
34
35 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
36 href="../../bootable/x86/kernel.xml"
37 xpointer="xpointer(//*[@os='p1'])"/>
38
39 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
40 href="../../bootable/x86/kernel.xml"
41 xpointer="xpointer(//*[@os='p2'])"/>
42
43 <para os="b">Install the kernel header files:</para>
44
45<screen os="c"><userinput>make mrproper
46make headers_check
47make INSTALL_HDR_PATH=/usr headers_install
48find /usr/include -name .install -or -name ..install.cmd | xargs rm -fv</userinput></screen>
49
50 <variablelist os="d">
51 <title>The meaning of the make commands:</title>
52
53 <varlistentry os="d1">
54 <term><parameter>make mrproper</parameter></term>
55 <listitem>
56 <para>Ensures that the kernel source dir is clean.</para>
57 </listitem>
58 </varlistentry>
59
60 <varlistentry os="d2">
61 <term><parameter>make headers_check</parameter></term>
62 <listitem>
63 <para>Sanitizes the raw kernel headers so that they can be used
64 by userspace programs.</para>
65 </listitem>
66 </varlistentry>
67
68 <varlistentry os="d3">
69 <term><parameter>make INSTALL_HDR_PATH=/usr headers_install</parameter></term>
70 <listitem>
71 <para>This will install the kernel headers into
72 <filename class="directory">/usr/include</filename>.</para>
73 </listitem>
74 </varlistentry>
75
76 <varlistentry os="d4">
77 <term><parameter>find /usr/include -name .install -or -name ..install.cmd | xargs rm -fv</parameter></term>
78 <listitem>
79 <para>Removes a number of unneeded debugging files that were installed.</para>
80 </listitem>
81 </varlistentry>
82
83 </variablelist>
84
85 </sect2>
86
87 <sect2 id="contents-linux-headers" role="content">
88 <title>Contents of Linux Headers</title>
89
90 <segmentedlist>
91 <segtitle>Installed headers</segtitle>
92 <segtitle>Installed directories</segtitle>
93
94 <seglistitem>
95 <seg>/usr/include/{asm,asm-generic,drm,linux,mtd,rdma,scsi,sound,video,xen}/*.h</seg>
96 <seg>/usr/include/asm, /usr/include/asm-generic, /usr/include/drm,
97 /usr/include/linux, /usr/include/mtd, /usr/include/rdma,
98 /usr/include/scsi, /usr/include/sound, /usr/include/uapi,
99 /usr/include/video, /usr/include/xen</seg>
100 </seglistitem>
101 </segmentedlist>
102
103 <variablelist>
104 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
105 <?dbfo list-presentation="list"?>
106 <?dbhtml list-presentation="table"?>
107
108 <varlistentry id="linux-headers">
109 <term><filename
110 class="headerfile">/usr/include/{asm,asm-generic,drm,linux,mtd,rdma,sound,video}/*.h</filename></term>
111 <listitem>
112 <para>The Linux API headers</para>
113 <indexterm zone="ch-system-linux-headers linux-headers">
114 <primary
115 sortas="e-/usr/include/{asm,linux}/*.h">/usr/include/{asm,linux}/*.h</primary>
116 </indexterm>
117 </listitem>
118 </varlistentry>
119
120 </variablelist>
121
122 </sect2>
123
124</sect1>
Note: See TracBrowser for help on using the repository browser.