source: chapter06/eudev.xml@ 0cba512d

10.0 10.0-rc1 10.1 10.1-rc1 11.0 11.0-rc1 11.0-rc2 11.0-rc3 11.1 11.1-rc1 11.2 11.2-rc1 11.3 11.3-rc1 12.0 12.0-rc1 12.1 12.1-rc1 8.0 8.1 8.2 8.3 8.4 9.0 9.1 arm bdubbs/gcc13 ml-11.0 multilib renodr/libudev-from-systemd s6-init trunk xry111/arm64 xry111/arm64-12.0 xry111/clfs-ng xry111/lfs-next xry111/loongarch xry111/loongarch-12.0 xry111/loongarch-12.1 xry111/mips64el xry111/pip3 xry111/rust-wip-20221008 xry111/update-glibc
Last change on this file since 0cba512d was 3e92f82, checked in by Bruce Dubbs <bdubbs@…>, 7 years ago

Update to linux-4.9.1.tar.xz.
Update to sed-4.3.tar.xz.
Update to gperf-3.1.

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

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