source: chapter05/kernel-headers.xml@ 38bb44a

6.0
Last change on this file since 38bb44a was 38bb44a, checked in by Gerard Beekmans <gerard@…>, 20 years ago

first round of printed layout fixes

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/testing/BOOK@4155 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

  • Property mode set to 100644
File size: 2.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
3 <!ENTITY % general-entities SYSTEM "../general.ent">
4 %general-entities;
5]>
6<sect1 id="ch-tools-kernel-headers" role="wrap">
7<title>Linux-&linux-version; Headers</title>
8<?dbhtml filename="kernel-headers.html"?>
9
10<indexterm zone="ch-tools-kernel-headers">
11<primary sortas="a-Linux">Linux</primary>
12<secondary>tools, headers</secondary></indexterm>
13
14<sect2 role="package"><title/>
15<para>The Linux kernel package contains the kernel source as well as
16the header files used by Glibc.</para>
17
18<segmentedlist>
19<segtitle>&buildtime;</segtitle>
20<segtitle>&diskspace;</segtitle>
21<seglistitem><seg>0.1 SBU</seg><seg>186 MB</seg></seglistitem>
22</segmentedlist>
23
24<segmentedlist>
25<segtitle>Linux Headers installation depends on</segtitle>
26<seglistitem><seg>Coreutils and Make</seg></seglistitem>
27</segmentedlist>
28
29</sect2>
30
31<sect2 role="installation">
32<title>Installation of the Kernel Headers</title>
33
34<para>Because some packages need to refer to the kernel header files,
35now is a good time to unpack the kernel archive, set it up, and copy
36the required files to a place where <command>gcc</command> can locate
37them later.</para>
38
39<para>Prepare for the header installation with:</para>
40
41<screen><userinput>make mrproper</userinput></screen>
42
43<para>This ensures that the kernel tree is absolutely clean. It is
44recommended that this command be issued prior to
45<emphasis>each</emphasis> kernel compilation. Do not assume that the
46source tree is automatically clean after un-tarring.</para>
47
48<para>Create the <filename class="headerfile">include/linux/version.h</filename>
49file:</para>
50
51<screen><userinput>make include/linux/version.h</userinput></screen>
52
53<para>Create the platform-specific <filename class="symlink">include/asm</filename>
54symlink:</para>
55
56<screen><userinput>make include/asm</userinput></screen>
57
58<para>Install the platform-specific header files:</para>
59
60<screen><userinput>mkdir /tools/glibc-kernheaders
61cp -HR include/asm /tools/glibc-kernheaders
62cp -R include/asm-generic /tools/glibc-kernheaders</userinput></screen>
63
64<beginpage/>
65<para>Finally, install the cross-platform kernel header files:</para>
66
67<screen><userinput>cp -R include/linux /tools/glibc-kernheaders</userinput></screen>
68
69</sect2>
70
71<sect2 role="content"><title/>
72<para>Details on this package are located in <xref
73linkend="contents-kernel" role="."/></para>
74</sect2>
75
76</sect1>
77
Note: See TracBrowser for help on using the repository browser.