linux-headers.xml 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  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. <sect1 id="ch-system-linux-headers" role="wrap">
  8. <?dbhtml filename="linux-headers.html"?>
  9. <title>Linux-&linux-version; API Headers</title>
  10. <indexterm zone="ch-system-linux-headers">
  11. <primary sortas="a-Linux">Linux</primary>
  12. <secondary>API headers</secondary>
  13. </indexterm>
  14. <sect2 role="package">
  15. <title/>
  16. <para>The Linux API Headers expose the kernel's API for use by Glibc.</para>
  17. <segmentedlist>
  18. <segtitle>&buildtime;</segtitle>
  19. <segtitle>&diskspace;</segtitle>
  20. <seglistitem>
  21. <seg>&linux-headers-ch6-sbu;</seg>
  22. <seg>&linux-headers-ch6-du;</seg>
  23. </seglistitem>
  24. </segmentedlist>
  25. </sect2>
  26. <sect2 role="installation">
  27. <title>Installation of Linux API Headers</title>
  28. <para>The Linux kernel needs to expose an Application Programming Interface
  29. (API) for the system's C library (Glibc in LFS) to utilize. This is done
  30. by way of sanitizing various C header files that are shipped in the Linux
  31. kernel source tarball.</para>
  32. <para>Apply a <command>sed</command> subsitution to suppress the
  33. installation of header files in <filename
  34. class='directory'>/usr/include/scsi</filename>. The versions provided by
  35. Glibc will be used instead:</para>
  36. <screen><userinput>sed -i '/scsi/d' include/Kbuild</userinput></screen>
  37. <para>Install the header files:</para>
  38. <screen><userinput>make mrproper
  39. make headers_check
  40. make INSTALL_HDR_PATH=dest headers_install
  41. cp -rv dest/include/* /usr/include</userinput></screen>
  42. </sect2>
  43. <sect2 id="contents-linux-headers" role="content">
  44. <title>Contents of Linux API Headers</title>
  45. <segmentedlist>
  46. <segtitle>Installed headers</segtitle>
  47. <seglistitem>
  48. <seg>/usr/include/{asm{,-generic},linux,mtd,rdma,sound}/*.h</seg>
  49. </seglistitem>
  50. </segmentedlist>
  51. <variablelist>
  52. <bridgehead renderas="sect3">Short Descriptions</bridgehead>
  53. <?dbfo list-presentation="list"?>
  54. <?dbhtml list-presentation="table"?>
  55. <varlistentry id="linux-headers">
  56. <term><filename class="headerfile">/usr/include/{asm{,-generic},linux,mtd,rdma,sound}/*.h</filename></term>
  57. <listitem>
  58. <para>The Linux API headers</para>
  59. <indexterm zone="ch-system-linux-headers linux-headers">
  60. <!-- No /*.h here to prevent a PDF line overflow -->
  61. <primary sortas="e-/usr/include/{asm{,-generic},linux,mtd,rdma,sound}">/usr/include/{asm{,-generic},linux,mtd,rdma,sound}</primary>
  62. </indexterm>
  63. </listitem>
  64. </varlistentry>
  65. </variablelist>
  66. </sect2>
  67. </sect1>