source: chapter06/kbd.xml@ c528e3a

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 7.4 7.5 7.6 7.7 7.8 7.9 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 c528e3a was c528e3a, checked in by Bruce Dubbs <bdubbs@…>, 11 years ago

Minor touchups

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

  • Property mode set to 100644
File size: 14.3 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-kbd" role="wrap">
9 <?dbhtml filename="kbd.html"?>
10
11 <sect1info condition="script">
12 <productname>kbd</productname>
13 <productnumber>&kbd-version;</productnumber>
14 <address>&kbd-url;</address>
15 </sect1info>
16
17 <title>Kbd-&kbd-version;</title>
18
19 <indexterm zone="ch-system-kbd">
20 <primary sortas="a-Kbd">Kbd</primary>
21 </indexterm>
22
23 <sect2 role="package">
24 <title/>
25
26 <para>The Kbd package contains key-table files, console fonts, and keyboard
27 utilities.</para>
28
29 <segmentedlist>
30 <segtitle>&buildtime;</segtitle>
31 <segtitle>&diskspace;</segtitle>
32
33 <seglistitem>
34 <seg>&kbd-ch6-sbu;</seg>
35 <seg>&kbd-ch6-du;</seg>
36 </seglistitem>
37 </segmentedlist>
38
39 </sect2>
40
41 <sect2 role="installation">
42 <title>Installation of Kbd</title>
43
44 <para>The behaviour of the Backspace and Delete keys is not consistent
45 across the keymaps in the Kbd package. The following patch fixes this
46 issue for i386 keymaps:</para>
47
48<screen><userinput remap="pre">patch -Np1 -i ../&kbd-backspace-patch;</userinput></screen>
49
50 <para>After patching, the Backspace key generates the character with code 127,
51 and the Delete key generates a well-known escape sequence.</para>
52
53 <para>Fix a bug that causes some keymaps not to be loaded correctly:</para>
54
55<screen><userinput remap="pre">sed -i -e '326 s/if/while/' src/loadkeys.analyze.l</userinput></screen>
56
57 <para>Remove the redundant <command>resizecons</command> program (it requires
58 the defunct svgalib to provide the video mode files - for normal use
59 <command>setfont</command> sizes the console appropriately) together with its
60 manpage.</para>
61
62<screen><userinput remap="pre">sed -i 's/\(RESIZECONS_PROGS=\)yes/\1no/g' configure
63sed -i 's/resizecons.8 //' man/man8/Makefile.in</userinput></screen>
64
65 <para>Prepare Kbd for compilation:</para>
66
67<screen><userinput remap="configure">./configure --prefix=/usr --datadir=/lib/kbd \
68 --disable-vlock</userinput></screen>
69
70 <variablelist>
71 <title>The meaning of the configure options:</title>
72
73 <varlistentry>
74 <term><parameter>--datadir=/lib/kbd</parameter></term>
75 <listitem>
76 <para>This option puts keyboard layout data in a directory that will
77 always be on the root partition instead of the default <filename
78 class="directory">/usr/share/kbd</filename>.</para>
79 </listitem>
80 </varlistentry>
81
82 <varlistentry>
83 <term><parameter>--disable-vlock</parameter></term>
84 <listitem>
85 <para>This option prevents the vlock utility from being built, as it
86 requires the PAM library, which isn't available in the chroot
87 environment.</para>
88 </listitem>
89 </varlistentry>
90
91 </variablelist>
92
93 <para>Compile the package:</para>
94
95<screen><userinput remap="make">make</userinput></screen>
96
97 <para>This package does not come with a test suite.</para>
98
99 <para>Install the package:</para>
100
101<screen><userinput remap="install">make install</userinput></screen>
102
103 <note>
104 <para>For some languages (e.g., Belarusian) the Kbd package doesn't
105 provide a useful keymap where the stock <quote>by</quote> keymap assumes
106 the ISO-8859-5 encoding, and the CP1251 keymap is normally used. Users of
107 such languages have to download working keymaps separately.</para>
108 </note>
109
110 <para>Some of the scripts in the LFS-Bootscripts package depend on
111 <command>kbd_mode</command>, <command>loadkeys</command>,
112 <command>openvt</command>, and
113 <command>setfont</command>. As <filename class="directory">/usr</filename>
114 may not be available during the early stages of booting, those binaries
115 need to be on the root partition:</para>
116
117<screen><userinput remap="install">mv -v /usr/bin/{kbd_mode,loadkeys,openvt,setfont} /bin</userinput></screen>
118
119 <para>If desired, install the documentation:</para>
120
121<screen><userinput remap="install">mkdir -v /usr/share/doc/kbd-&kbd-version;
122cp -R -v doc/* \
123 /usr/share/doc/kbd-&kbd-version;</userinput></screen>
124
125 </sect2>
126
127 <sect2 id="contents-kbd" role="content">
128 <title>Contents of Kbd</title>
129
130 <segmentedlist>
131 <segtitle>Installed programs</segtitle>
132 <segtitle>Installed directory</segtitle>
133
134 <seglistitem>
135 <seg>chvt, deallocvt, dumpkeys, fgconsole, getkeycodes, kbdinfo,
136 kbd_mode, kbdrate, loadkeys, loadunimap,
137 mapscrn, openvt, psfaddtable (link to psfxtable), psfgettable (link to
138 psfxtable), psfstriptable (link to psfxtable), psfxtable, <!--resizecons,-->
139 setfont, setkeycodes, setleds, setmetamode,
140 showconsolefont, showkey, unicode_start, and unicode_stop</seg>
141 <seg>/lib/kbd</seg>
142 </seglistitem>
143 </segmentedlist>
144
145 <variablelist>
146 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
147 <?dbfo list-presentation="list"?>
148 <?dbhtml list-presentation="table"?>
149
150 <varlistentry id="chvt">
151 <term><command>chvt</command></term>
152 <listitem>
153 <para>Changes the foreground virtual terminal</para>
154 <indexterm zone="ch-system-kbd chvt">
155 <primary sortas="b-chvt">chvt</primary>
156 </indexterm>
157 </listitem>
158 </varlistentry>
159
160 <varlistentry id="deallocvt">
161 <term><command>deallocvt</command></term>
162 <listitem>
163 <para>Deallocates unused virtual terminals</para>
164 <indexterm zone="ch-system-kbd deallocvt">
165 <primary sortas="b-deallocvt">deallocvt</primary>
166 </indexterm>
167 </listitem>
168 </varlistentry>
169
170 <varlistentry id="dumpkeys">
171 <term><command>dumpkeys</command></term>
172 <listitem>
173 <para>Dumps the keyboard translation tables</para>
174 <indexterm zone="ch-system-kbd dumpkeys">
175 <primary sortas="b-dumpkeys">dumpkeys</primary>
176 </indexterm>
177 </listitem>
178 </varlistentry>
179
180 <varlistentry id="fgconsole">
181 <term><command>fgconsole</command></term>
182 <listitem>
183 <para>Prints the number of the active virtual terminal</para>
184 <indexterm zone="ch-system-kbd fgconsole">
185 <primary sortas="b-fgconsole">fgconsole</primary>
186 </indexterm>
187 </listitem>
188 </varlistentry>
189
190 <varlistentry id="getkeycodes">
191 <term><command>getkeycodes</command></term>
192 <listitem>
193 <para>Prints the kernel scancode-to-keycode mapping table</para>
194 <indexterm zone="ch-system-kbd getkeycodes">
195 <primary sortas="b-getkeycodes">getkeycodes</primary>
196 </indexterm>
197 </listitem>
198 </varlistentry>
199
200 <varlistentry id="kbdinfo">
201 <term><command>kbdinfo</command></term>
202 <listitem>
203 <para>Obtains information about the status of a console</para>
204 <indexterm zone="ch-system-kbd kbdinfo">
205 <primary sortas="b-kbdinfo">kbdinfo</primary>
206 </indexterm>
207 </listitem>
208 </varlistentry>
209
210 <varlistentry id="kbd_mode">
211 <term><command>kbd_mode</command></term>
212 <listitem>
213 <para>Reports or sets the keyboard mode</para>
214 <indexterm zone="ch-system-kbd kbd_mode">
215 <primary sortas="b-kbd_mode">kbd_mode</primary>
216 </indexterm>
217 </listitem>
218 </varlistentry>
219
220 <varlistentry id="kbdrate">
221 <term><command>kbdrate</command></term>
222 <listitem>
223 <para>Sets the keyboard repeat and delay rates</para>
224 <indexterm zone="ch-system-kbd kbdrate">
225 <primary sortas="b-kbdrate">kbdrate</primary>
226 </indexterm>
227 </listitem>
228 </varlistentry>
229
230 <varlistentry id="loadkeys">
231 <term><command>loadkeys</command></term>
232 <listitem>
233 <para>Loads the keyboard translation tables</para>
234 <indexterm zone="ch-system-kbd loadkeys">
235 <primary sortas="b-loadkeys">loadkeys</primary>
236 </indexterm>
237 </listitem>
238 </varlistentry>
239
240 <varlistentry id="loadunimap">
241 <term><command>loadunimap</command></term>
242 <listitem>
243 <para>Loads the kernel unicode-to-font mapping table</para>
244 <indexterm zone="ch-system-kbd loadunimap">
245 <primary sortas="b-loadunimap">loadunimap</primary>
246 </indexterm>
247 </listitem>
248 </varlistentry>
249
250 <varlistentry id="mapscrn">
251 <term><command>mapscrn</command></term>
252 <listitem>
253 <para>An obsolete program that used to load a user-defined output
254 character mapping table into the console driver; this is now done
255 by <command>setfont</command></para>
256 <indexterm zone="ch-system-kbd mapscrn">
257 <primary sortas="b-mapscrn">mapscrn</primary>
258 </indexterm>
259 </listitem>
260 </varlistentry>
261
262 <varlistentry id="openvt">
263 <term><command>openvt</command></term>
264 <listitem>
265 <para>Starts a program on a new virtual terminal (VT)</para>
266 <indexterm zone="ch-system-kbd openvt">
267 <primary sortas="b-openvt">openvt</primary>
268 </indexterm>
269 </listitem>
270 </varlistentry>
271
272 <varlistentry id="psfaddtable">
273 <term><command>psfaddtable</command></term>
274 <listitem>
275 <para>A link to <command>psfxtable</command></para>
276 <indexterm zone="ch-system-kbd psfaddtable">
277 <primary sortas="b-psfaddtable">psfaddtable</primary>
278 </indexterm>
279 </listitem>
280 </varlistentry>
281
282 <varlistentry id="psfgettable">
283 <term><command>psfgettable</command></term>
284 <listitem>
285 <para>A link to <command>psfxtable</command></para>
286 <indexterm zone="ch-system-kbd psfgettable">
287 <primary sortas="b-psfgettable">psfgettable</primary>
288 </indexterm>
289 </listitem>
290 </varlistentry>
291
292 <varlistentry id="psfstriptable">
293 <term><command>psfstriptable</command></term>
294 <listitem>
295 <para>A link to <command>psfxtable</command></para>
296 <indexterm zone="ch-system-kbd psfstriptable">
297 <primary sortas="b-psfstriptable">psfstriptable</primary>
298 </indexterm>
299 </listitem>
300 </varlistentry>
301
302 <varlistentry id="psfxtable">
303 <term><command>psfxtable</command></term>
304 <listitem>
305 <para>Handle Unicode character tables for console fonts</para>
306 <indexterm zone="ch-system-kbd psfxtable">
307 <primary sortas="b-psfxtable">psfxtable</primary>
308 </indexterm>
309 </listitem>
310 </varlistentry>
311
312 <!--<varlistentry id="resizecons">
313 <term><command>resizecons</command></term>
314 <listitem>
315 <para>Changes the kernel idea of the console size</para>
316 <indexterm zone="ch-system-kbd resizecons">
317 <primary sortas="b-resizecons">resizecons</primary>
318 </indexterm>
319 </listitem>
320 </varlistentry>-->
321
322 <varlistentry id="setfont">
323 <term><command>setfont</command></term>
324 <listitem>
325 <para>Changes the Enhanced Graphic Adapter (EGA) and Video Graphics
326 Array (VGA) fonts on the console</para>
327 <indexterm zone="ch-system-kbd setfont">
328 <primary sortas="b-setfont">setfont</primary>
329 </indexterm>
330 </listitem>
331 </varlistentry>
332
333 <varlistentry id="setkeycodes">
334 <term><command>setkeycodes</command></term>
335 <listitem>
336 <para>Loads kernel scancode-to-keycode mapping table entries; this is
337 useful if there are unusual keys on the keyboard</para>
338 <indexterm zone="ch-system-kbd setkeycodes">
339 <primary sortas="b-setkeycodes">setkeycodes</primary>
340 </indexterm>
341 </listitem>
342 </varlistentry>
343
344 <varlistentry id="setleds">
345 <term><command>setleds</command></term>
346 <listitem>
347 <para>Sets the keyboard flags and Light Emitting Diodes (LEDs)</para>
348 <indexterm zone="ch-system-kbd setleds">
349 <primary sortas="b-setleds">setleds</primary>
350 </indexterm>
351 </listitem>
352 </varlistentry>
353
354 <varlistentry id="setmetamode">
355 <term><command>setmetamode</command></term>
356 <listitem>
357 <para>Defines the keyboard meta-key handling</para>
358 <indexterm zone="ch-system-kbd setmetamode">
359 <primary sortas="b-setmetamode">setmetamode</primary>
360 </indexterm>
361 </listitem>
362 </varlistentry>
363
364 <varlistentry id="showconsolefont">
365 <term><command>showconsolefont</command></term>
366 <listitem>
367 <para>Shows the current EGA/VGA console screen font</para>
368 <indexterm zone="ch-system-kbd showconsolefont">
369 <primary sortas="b-showconsolefont">showconsolefont</primary>
370 </indexterm>
371 </listitem>
372 </varlistentry>
373
374 <varlistentry id="showkey">
375 <term><command>showkey</command></term>
376 <listitem>
377 <para>Reports the scancodes, keycodes, and ASCII codes of the keys
378 pressed on the keyboard</para>
379 <indexterm zone="ch-system-kbd showkey">
380 <primary sortas="b-showkey">showkey</primary>
381 </indexterm>
382 </listitem>
383 </varlistentry>
384
385 <varlistentry id="unicode_start">
386 <term><command>unicode_start</command></term>
387 <listitem>
388 <para>Puts the keyboard and console in UNICODE mode. Don't use this
389 program unless your keymap file is in the ISO-8859-1 encoding. For
390 other encodings, this utility produces incorrect results.</para>
391 <indexterm zone="ch-system-kbd unicode_start">
392 <primary sortas="b-unicode_start">unicode_start</primary>
393 </indexterm>
394 </listitem>
395 </varlistentry>
396
397 <varlistentry id="unicode_stop">
398 <term><command>unicode_stop</command></term>
399 <listitem>
400 <para>Reverts keyboard and console from UNICODE mode</para>
401 <indexterm zone="ch-system-kbd unicode_stop">
402 <primary sortas="b-unicode_stop">unicode_stop</primary>
403 </indexterm>
404 </listitem>
405 </varlistentry>
406
407 </variablelist>
408
409 </sect2>
410
411</sect1>
Note: See TracBrowser for help on using the repository browser.