eudev.xml 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205
  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-eudev" role="wrap" revision="sysv">
  8. <?dbhtml filename="eudev.html"?>
  9. <sect1info condition="script">
  10. <productname>eudev</productname>
  11. <productnumber>&eudev-version;</productnumber>
  12. <address>&eudev-url;</address>
  13. </sect1info>
  14. <title>Eudev-&eudev-version;</title>
  15. <indexterm zone="ch-system-eudev">
  16. <primary sortas="a-Eudev">Eudev</primary>
  17. </indexterm>
  18. <sect2 role="package">
  19. <title/>
  20. <para>The Eudev package contains programs for dynamic creation of device
  21. nodes.</para>
  22. <segmentedlist>
  23. <segtitle>&buildtime;</segtitle>
  24. <segtitle>&diskspace;</segtitle>
  25. <seglistitem>
  26. <seg>&eudev-ch6-sbu;</seg>
  27. <seg>&eudev-ch6-du;</seg>
  28. </seglistitem>
  29. </segmentedlist>
  30. </sect2>
  31. <sect2 role="installation">
  32. <title>Installation of Eudev</title>
  33. <para>First, fix a test script:</para>
  34. <screen><userinput remap="pre">sed -r -i 's|/usr(/bin/test)|\1|' test/udev-test.pl</userinput></screen>
  35. <para>Next, add a workaround to prevent the /tools directory from being
  36. hard coded into Eudev binary files library locations:</para>
  37. <screen><userinput remap="pre">cat &gt; config.cache &lt;&lt; "EOF"
  38. HAVE_BLKID=1
  39. BLKID_LIBS="-lblkid"
  40. BLKID_CFLAGS="-I/tools/include"
  41. EOF</userinput></screen>
  42. <para>Prepare Eudev for compilation:</para>
  43. <screen><userinput remap="configure">./configure --prefix=/usr \
  44. --bindir=/sbin \
  45. --sbindir=/sbin \
  46. --libdir=/usr/lib \
  47. --sysconfdir=/etc \
  48. --libexecdir=/lib \
  49. --with-rootprefix= \
  50. --with-rootlibdir=/lib \
  51. --enable-manpages \
  52. --disable-static \
  53. --config-cache</userinput></screen>
  54. <!-- Seems to be unneeded - but leave as a comment for a while
  55. - -disable-gudev \
  56. - -enable-split-usr \
  57. - -enable-hwdb \
  58. - -disable-introspection \
  59. - -disable-gtk-doc-html</userinput></screen>
  60. -->
  61. <para>Compile the package:</para>
  62. <screen><userinput remap="make">LIBRARY_PATH=/tools/lib make</userinput></screen>
  63. <para>Create some directories now that are needed for tests, but
  64. will also be used as a part of installation:</para>
  65. <screen><userinput remap="test">mkdir -pv /lib/udev/rules.d
  66. mkdir -pv /etc/udev/rules.d</userinput></screen>
  67. <para>To test the results, issue:</para>
  68. <screen><userinput remap="test">make LD_LIBRARY_PATH=/tools/lib check</userinput></screen>
  69. <para>Install the package:</para>
  70. <screen><userinput remap="install">make LD_LIBRARY_PATH=/tools/lib install</userinput></screen>
  71. <para>Install some custom rules and support files useful in an LFS
  72. environment:</para>
  73. <screen><userinput remap="install">tar -xvf ../&udev-lfs-version;.tar.bz2
  74. make -f &udev-lfs-version;/Makefile.lfs install</userinput></screen>
  75. </sect2>
  76. <sect2 id="conf-eudev" role="configuration">
  77. <title>Configuring Eudev</title>
  78. <indexterm zone="conf-eudev">
  79. <primary sortas="a-Eudev">Eudev</primary>
  80. <secondary>configuring</secondary>
  81. </indexterm>
  82. <indexterm zone="conf-eudev">
  83. <primary sortas="e-/etc/udev/hwdb.bin">/etc/udev/hwdb.bin</primary>
  84. </indexterm>
  85. <para>Information about hardware devices is maintained in the
  86. <filename class="directory">/etc/udev/hwdb.d</filename> and
  87. <filename class="directory">/usr/lib/udev/hwdb.d</filename> directories.
  88. <application>Eudev</application> needs that information to be compiled
  89. into a binary database <filename>/etc/udev/hwdb.bin</filename>. Create the
  90. initial database:</para>
  91. <screen><userinput>LD_LIBRARY_PATH=/tools/lib udevadm hwdb --update</userinput></screen>
  92. <para>This command needs to be run each time the hardware information is
  93. updated.</para>
  94. </sect2>
  95. <sect2 id="contents-eudev" role="content">
  96. <title>Contents of Eudev</title>
  97. <segmentedlist>
  98. <segtitle>Installed programs</segtitle>
  99. <segtitle>Installed libraries</segtitle>
  100. <segtitle>Installed directories</segtitle>
  101. <seglistitem>
  102. <seg><!-- These are in /lib/udev and not to be called by the user:
  103. accelerometer, ata_id, cdrom_id, collect, mtd_probe,
  104. scsi_id, v4l_id,--> udevadm and udevd</seg>
  105. <seg>libudev.so</seg>
  106. <seg>/etc/udev, /lib/udev, and /usr/share/doc/udev-20140408</seg>
  107. </seglistitem>
  108. </segmentedlist>
  109. <variablelist>
  110. <bridgehead renderas="sect3">Short Descriptions</bridgehead>
  111. <?dbfo list-presentation="list"?>
  112. <?dbhtml list-presentation="table"?>
  113. <varlistentry id="udevadm" revision="sysv">
  114. <term><command>udevadm</command></term>
  115. <listitem>
  116. <para>Generic udev administration tool: controls the udevd daemon,
  117. provides info from the Udev database, monitors uevents, waits for
  118. uevents to finish, tests Udev configuration, and triggers uevents
  119. for a given device</para>
  120. <indexterm zone="ch-system-eudev udevadm">
  121. <primary sortas="b-udevadm">udevadm</primary>
  122. </indexterm>
  123. </listitem>
  124. </varlistentry>
  125. <varlistentry id="udevd">
  126. <term><command>udevd</command></term>
  127. <listitem>
  128. <para>A daemon that listens for uevents on the netlink socket,
  129. creates devices and runs the configured external programs in
  130. response to these uevents</para>
  131. <indexterm zone="ch-system-eudev udevd">
  132. <primary sortas="b-udevd">udevd</primary>
  133. </indexterm>
  134. </listitem>
  135. </varlistentry>
  136. <varlistentry id="libudev">
  137. <term><filename class="libraryfile">libudev</filename></term>
  138. <listitem>
  139. <para>A library interface to udev device information</para>
  140. <indexterm zone="ch-system-eudev libudev">
  141. <primary sortas="c-libudev">libudev</primary>
  142. </indexterm>
  143. </listitem>
  144. </varlistentry>
  145. <varlistentry id="etc-udev">
  146. <term><filename class="directory">/etc/udev</filename></term>
  147. <listitem>
  148. <para>Contains Udev configuration files,
  149. device permissions, and rules for device naming</para>
  150. <indexterm zone="ch-system-eudev etc-udev">
  151. <primary sortas="e-/etc/udev">/etc/udev</primary>
  152. </indexterm>
  153. </listitem>
  154. </varlistentry>
  155. </variablelist>
  156. </sect2>
  157. </sect1>