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 | <!ENTITY gpm-download-http "&sources-anduin-http;/gpm/gpm-&gpm-version;.tar.bz2">
|
---|
8 | <!ENTITY gpm-download-ftp "&sources-anduin-ftp;/gpm/gpm-&gpm-version;.tar.bz2">
|
---|
9 | <!ENTITY gpm-md5sum "bf84143905a6a903dbd4d4b911a2a2b8">
|
---|
10 | <!ENTITY gpm-size "820 KB">
|
---|
11 | <!ENTITY gpm-buildsize "7.4 MB">
|
---|
12 | <!ENTITY gpm-time "0.1 SBU">
|
---|
13 | ]>
|
---|
14 |
|
---|
15 | <sect1 id="gpm" xreflabel="GPM-&gpm-version;">
|
---|
16 | <?dbhtml filename="gpm.html"?>
|
---|
17 |
|
---|
18 | <sect1info>
|
---|
19 | <date>$Date$</date>
|
---|
20 | </sect1info>
|
---|
21 |
|
---|
22 | <title>GPM-&gpm-version;</title>
|
---|
23 |
|
---|
24 | <indexterm zone="gpm">
|
---|
25 | <primary sortas="a-GPM">GPM</primary>
|
---|
26 | </indexterm>
|
---|
27 |
|
---|
28 | <sect2 role="package">
|
---|
29 | <title>Introduction to GPM</title>
|
---|
30 |
|
---|
31 | <para>
|
---|
32 | The <application>GPM</application> (General Purpose Mouse daemon)
|
---|
33 | package contains a mouse server for the console and
|
---|
34 | <command>xterm</command>. It not only provides cut and paste support
|
---|
35 | generally, but its library component is used by various software such as
|
---|
36 | <application>Links</application> to provide mouse support to the
|
---|
37 | application. It is useful on desktops, especially if following (Beyond)
|
---|
38 | Linux From Scratch instructions; it's often much easier (and less error
|
---|
39 | prone) to cut and paste between two console windows than to type
|
---|
40 | everything by hand!
|
---|
41 | </para>
|
---|
42 |
|
---|
43 | &lfs110_checked;
|
---|
44 |
|
---|
45 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
46 | <itemizedlist spacing="compact">
|
---|
47 | <listitem>
|
---|
48 | <para>
|
---|
49 | Download (HTTP): <ulink url="&gpm-download-http;"/>
|
---|
50 | </para>
|
---|
51 | </listitem>
|
---|
52 | <listitem>
|
---|
53 | <para>
|
---|
54 | Download (FTP): <ulink url="&gpm-download-ftp;"/>
|
---|
55 | </para>
|
---|
56 | </listitem>
|
---|
57 | <listitem>
|
---|
58 | <para>
|
---|
59 | Download MD5 sum: &gpm-md5sum;
|
---|
60 | </para>
|
---|
61 | </listitem>
|
---|
62 | <listitem>
|
---|
63 | <para>
|
---|
64 | Download size: &gpm-size;
|
---|
65 | </para>
|
---|
66 | </listitem>
|
---|
67 | <listitem>
|
---|
68 | <para>
|
---|
69 | Estimated disk space required: &gpm-buildsize;
|
---|
70 | </para>
|
---|
71 | </listitem>
|
---|
72 | <listitem>
|
---|
73 | <para>
|
---|
74 | Estimated build time: &gpm-time;
|
---|
75 | </para>
|
---|
76 | </listitem>
|
---|
77 | </itemizedlist>
|
---|
78 |
|
---|
79 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
80 | <itemizedlist spacing="compact">
|
---|
81 | <listitem>
|
---|
82 | <para>
|
---|
83 | Required patch:
|
---|
84 | <ulink url="&patch-root;/gpm-&gpm-version;-consolidated-1.patch"/>
|
---|
85 | </para>
|
---|
86 | </listitem>
|
---|
87 | </itemizedlist>
|
---|
88 |
|
---|
89 | <para condition="html" role="usernotes">User Notes:
|
---|
90 | <ulink url="&blfs-wiki;/GPM"/></para>
|
---|
91 |
|
---|
92 | </sect2>
|
---|
93 |
|
---|
94 | <sect2 role="kernel" id='gpm-kernel'>
|
---|
95 | <title>Kernel Configuration</title>
|
---|
96 |
|
---|
97 | <para>
|
---|
98 | Enable the following option in the kernel configuration and recompile the
|
---|
99 | kernel if necessary:
|
---|
100 | </para>
|
---|
101 |
|
---|
102 | <screen><literal>Device Drivers --->
|
---|
103 | Input device support ---> [CONFIG_INPUT]
|
---|
104 | <*/M> Mouse interface [CONFIG_INPUT_MOUSEDEV]</literal></screen>
|
---|
105 |
|
---|
106 | <indexterm zone="gpm gpm-kernel">
|
---|
107 | <primary sortas="d-gpm">gpm</primary>
|
---|
108 | </indexterm>
|
---|
109 |
|
---|
110 | </sect2>
|
---|
111 |
|
---|
112 | <sect2 role="installation">
|
---|
113 | <title>Installation of GPM</title>
|
---|
114 |
|
---|
115 | <para>
|
---|
116 | Install <application>GPM</application> by running
|
---|
117 | the following commands:
|
---|
118 | </para>
|
---|
119 |
|
---|
120 | <screen><userinput>patch -Np1 -i ../gpm-&gpm-version;-consolidated-1.patch &&
|
---|
121 | ./autogen.sh &&
|
---|
122 | ./configure --prefix=/usr --sysconfdir=/etc &&
|
---|
123 | make</userinput></screen>
|
---|
124 |
|
---|
125 | <para>
|
---|
126 | This package does not come with a test suite.
|
---|
127 | </para>
|
---|
128 |
|
---|
129 | <para>
|
---|
130 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
131 | </para>
|
---|
132 |
|
---|
133 | <screen role="root"><userinput>make install &&
|
---|
134 |
|
---|
135 | install-info --dir-file=/usr/share/info/dir \
|
---|
136 | /usr/share/info/gpm.info &&
|
---|
137 |
|
---|
138 | rm -fv /usr/lib/libgpm.a &&
|
---|
139 | ln -sfv libgpm.so.2.1.0 /usr/lib/libgpm.so &&
|
---|
140 | install -v -m644 conf/gpm-root.conf /etc &&
|
---|
141 |
|
---|
142 | install -v -m755 -d /usr/share/doc/gpm-&gpm-version;/support &&
|
---|
143 | install -v -m644 doc/support/* \
|
---|
144 | /usr/share/doc/gpm-&gpm-version;/support &&
|
---|
145 | install -v -m644 doc/{FAQ,HACK_GPM,README*} \
|
---|
146 | /usr/share/doc/gpm-&gpm-version;</userinput></screen>
|
---|
147 |
|
---|
148 | </sect2>
|
---|
149 |
|
---|
150 | <sect2 role="commands">
|
---|
151 | <title>Command Explanations</title>
|
---|
152 |
|
---|
153 | <para>
|
---|
154 | <command>./autogen.sh</command>: This command creates the missing
|
---|
155 | <command>configure</command> script.
|
---|
156 | </para>
|
---|
157 |
|
---|
158 | <para>
|
---|
159 | <command>install-info ...</command>: This package installs a
|
---|
160 | <filename class="extension">.info</filename> file, but does not update
|
---|
161 | the system <filename>dir</filename> file. This command makes the update.
|
---|
162 | </para>
|
---|
163 |
|
---|
164 | <para>
|
---|
165 | <command>ln -v -sfn libgpm.so.2.1.0 /usr/lib/libgpm.so</command>: This
|
---|
166 | command is used to create (or update) the <filename
|
---|
167 | class="extension">.so</filename> symlink to the library.
|
---|
168 | </para>
|
---|
169 |
|
---|
170 | </sect2>
|
---|
171 |
|
---|
172 | <sect2 role="configuration">
|
---|
173 | <title>Configuring GPM</title>
|
---|
174 |
|
---|
175 | <sect3 id="gpm-init">
|
---|
176 | <title><phrase revision="sysv">Boot Script</phrase>
|
---|
177 | <phrase revision="systemd">Systemd Unit</phrase></title>
|
---|
178 |
|
---|
179 | <indexterm zone="gpm gpm-init">
|
---|
180 | <primary sortas="f-gpm-init">gpm</primary>
|
---|
181 | </indexterm>
|
---|
182 |
|
---|
183 | <para revision="sysv">
|
---|
184 | Install the
|
---|
185 | <filename>/etc/rc.d/init.d/gpm</filename> init script included in the
|
---|
186 | <xref linkend="bootscripts"/> package.
|
---|
187 | </para>
|
---|
188 |
|
---|
189 | <para revision="systemd">
|
---|
190 | To start the <command>gpm</command> daemon at boot,
|
---|
191 | install the systemd unit from the <xref linkend="systemd-units"/>
|
---|
192 | package by running the following command as the
|
---|
193 | <systemitem class="username">root</systemitem> user:
|
---|
194 | </para>
|
---|
195 |
|
---|
196 | <screen role="root"><userinput>make install-gpm</userinput></screen>
|
---|
197 |
|
---|
198 | </sect3>
|
---|
199 |
|
---|
200 | <sect3 id="gpm-config">
|
---|
201 | <title>Config Files</title>
|
---|
202 |
|
---|
203 | <para>
|
---|
204 | <filename>/etc/gpm-root.conf</filename> and
|
---|
205 | <filename>~/.gpm-root</filename>: The default and individual user
|
---|
206 | <command>gpm-root</command> configuration files.
|
---|
207 | </para>
|
---|
208 |
|
---|
209 | <para revision="sysv">
|
---|
210 | <filename>/etc/sysconfig/mouse</filename>:
|
---|
211 | This file contains the name of your mouse device and the protocol
|
---|
212 | it uses. To create this file, run the following as the
|
---|
213 | <systemitem class="username">root</systemitem> user:
|
---|
214 | </para>
|
---|
215 |
|
---|
216 | <screen role="root" revision="sysv"><userinput>cat > /etc/sysconfig/mouse << "EOF"
|
---|
217 | <literal># Begin /etc/sysconfig/mouse
|
---|
218 |
|
---|
219 | MDEVICE="<replaceable><yourdevice></replaceable>"
|
---|
220 | PROTOCOL="<replaceable><yourprotocol></replaceable>"
|
---|
221 | GPMOPTS="<replaceable><additional options></replaceable>"
|
---|
222 |
|
---|
223 | # End /etc/sysconfig/mouse</literal>
|
---|
224 | EOF</userinput></screen>
|
---|
225 |
|
---|
226 | <indexterm zone="gpm gpm-config">
|
---|
227 | <primary sortas="e-AA.gpm-root">~/.gpm-root</primary>
|
---|
228 | </indexterm>
|
---|
229 |
|
---|
230 | <indexterm zone="gpm gpm-config">
|
---|
231 | <primary sortas="e-etc-gpm-root.conf">/etc/gpm-root.conf</primary>
|
---|
232 | </indexterm>
|
---|
233 |
|
---|
234 | <indexterm zone="gpm gpm-config" revision="sysv">
|
---|
235 | <primary sortas="e-etc-sysconfig-mouse">/etc/sysconfig/mouse</primary>
|
---|
236 | </indexterm>
|
---|
237 |
|
---|
238 | </sect3>
|
---|
239 |
|
---|
240 | <sect3>
|
---|
241 | <title>Configuration Information</title>
|
---|
242 |
|
---|
243 | <para revision="sysv">
|
---|
244 | Examples of values to set <envar>MDEVICE</envar>,
|
---|
245 | <envar>PROTOCOL</envar>, and <envar>GPMOPTS</envar> to are:
|
---|
246 | </para>
|
---|
247 |
|
---|
248 | <screen revision="sysv"><literal>MDEVICE="/dev/input/mice"
|
---|
249 | PROTOCOL="imps2"
|
---|
250 | GPMOPTS=""</literal></screen>
|
---|
251 |
|
---|
252 | <para revision="sysv">
|
---|
253 | A list of which protocol values are known can be found by running
|
---|
254 | <command>gpm -m <replaceable>[device]</replaceable> -t -help</command>.
|
---|
255 | The <envar>MDEVICE</envar> setting depends on which type of mouse you
|
---|
256 | have. For example, <filename>/dev/ttyS0</filename> for a serial mouse
|
---|
257 | (on Windows this is COM1), <filename>/dev/input/mice</filename> is
|
---|
258 | often used for USB mice and <filename>/dev/psaux</filename> for PS2
|
---|
259 | mice. <envar>GPMOPTS</envar> is the 'catch all' for any additional
|
---|
260 | options that are needed for your hardware.
|
---|
261 | </para>
|
---|
262 |
|
---|
263 | <para revision="systemd">
|
---|
264 | <application>GPM</application> is by default started with
|
---|
265 | the following parameters:
|
---|
266 | <parameter>-m /dev/input/mice -t imps2</parameter>. If the
|
---|
267 | mentioned parameters don't suit your needs, you can override
|
---|
268 | them by running the following commands as
|
---|
269 | the <systemitem class="username">root</systemitem> user:
|
---|
270 | </para>
|
---|
271 |
|
---|
272 | <screen role="nodump" revision="systemd"><userinput>install -v -dm755 /etc/systemd/system/gpm.service.d &&
|
---|
273 | cat > /etc/systemd/system/gpm.service.d/99-user.conf << EOF
|
---|
274 | <literal>[Service]
|
---|
275 | ExecStart=/usr/sbin/gpm <replaceable><list of parameters></replaceable>
|
---|
276 | </literal>EOF</userinput></screen>
|
---|
277 |
|
---|
278 | </sect3>
|
---|
279 |
|
---|
280 | </sect2>
|
---|
281 |
|
---|
282 | <sect2 role="content">
|
---|
283 | <title>Contents</title>
|
---|
284 |
|
---|
285 | <segmentedlist>
|
---|
286 | <segtitle>Installed Programs</segtitle>
|
---|
287 | <segtitle>Installed Library</segtitle>
|
---|
288 | <segtitle>Installed Directory</segtitle>
|
---|
289 |
|
---|
290 | <seglistitem>
|
---|
291 | <seg>disable-paste, display-buttons, display-coords, get-versions, gpm,
|
---|
292 | gpm-root, hltest, mev, and mouse-test</seg>
|
---|
293 | <seg>libgpm.so</seg>
|
---|
294 | <seg>/usr/share/doc/gpm-&gpm-version;</seg>
|
---|
295 | </seglistitem>
|
---|
296 | </segmentedlist>
|
---|
297 |
|
---|
298 | <variablelist>
|
---|
299 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
300 | <?dbfo list-presentation="list"?>
|
---|
301 | <?dbhtml list-presentation="table"?>
|
---|
302 |
|
---|
303 | <varlistentry id="disable-paste">
|
---|
304 | <term><command>disable-paste</command></term>
|
---|
305 | <listitem>
|
---|
306 | <para>
|
---|
307 | is a security mechanism used to disable the paste buffer
|
---|
308 | </para>
|
---|
309 | <indexterm zone="gpm disable-paste">
|
---|
310 | <primary sortas="b-disable-paste">disable-paste</primary>
|
---|
311 | </indexterm>
|
---|
312 | </listitem>
|
---|
313 | </varlistentry>
|
---|
314 |
|
---|
315 | <varlistentry id="display-buttons">
|
---|
316 | <term><command>display-buttons</command></term>
|
---|
317 | <listitem>
|
---|
318 | <para>
|
---|
319 | is a simple program that reports the mouse buttons being
|
---|
320 | pressed and released
|
---|
321 | </para>
|
---|
322 | <indexterm zone="gpm display-buttons">
|
---|
323 | <primary sortas="b-display-buttons">display-buttons</primary>
|
---|
324 | </indexterm>
|
---|
325 | </listitem>
|
---|
326 | </varlistentry>
|
---|
327 |
|
---|
328 | <varlistentry id="display-coords">
|
---|
329 | <term><command>display-coords</command></term>
|
---|
330 | <listitem>
|
---|
331 | <para>
|
---|
332 | is a simple program that reports the mouse coordinates
|
---|
333 | </para>
|
---|
334 | <indexterm zone="gpm display-coords">
|
---|
335 | <primary sortas="b-display-coords">display-coords</primary>
|
---|
336 | </indexterm>
|
---|
337 | </listitem>
|
---|
338 | </varlistentry>
|
---|
339 |
|
---|
340 | <varlistentry id="get-versions">
|
---|
341 | <term><command>get-versions</command></term>
|
---|
342 | <listitem>
|
---|
343 | <para>
|
---|
344 | is used to report the <application>GPM</application> library
|
---|
345 | and server versions
|
---|
346 | </para>
|
---|
347 | <indexterm zone="gpm get-versions">
|
---|
348 | <primary sortas="b-get-versions">get-versions</primary>
|
---|
349 | </indexterm>
|
---|
350 | </listitem>
|
---|
351 | </varlistentry>
|
---|
352 |
|
---|
353 | <varlistentry id="gpm-prog">
|
---|
354 | <term><command>gpm</command></term>
|
---|
355 | <listitem>
|
---|
356 | <para>
|
---|
357 | is a cut and paste utility and mouse server for virtual consoles
|
---|
358 | </para>
|
---|
359 | <indexterm zone="gpm gpm-prog">
|
---|
360 | <primary sortas="b-gpm">gpm</primary>
|
---|
361 | </indexterm>
|
---|
362 | </listitem>
|
---|
363 | </varlistentry>
|
---|
364 |
|
---|
365 | <varlistentry id="gpm-root">
|
---|
366 | <term><command>gpm-root</command></term>
|
---|
367 | <listitem>
|
---|
368 | <para>
|
---|
369 | is a default handler for <command>gpm</command>. It is used to
|
---|
370 | draw menus on the root window
|
---|
371 | </para>
|
---|
372 | <indexterm zone="gpm gpm-root">
|
---|
373 | <primary sortas="b-gpm-root">gpm-root</primary>
|
---|
374 | </indexterm>
|
---|
375 | </listitem>
|
---|
376 | </varlistentry>
|
---|
377 |
|
---|
378 | <varlistentry id="hltest">
|
---|
379 | <term><command>hltest</command></term>
|
---|
380 | <listitem>
|
---|
381 | <para>
|
---|
382 | is a simple sample application using the high-level library, meant
|
---|
383 | to be read by programmers trying to use the high-level library
|
---|
384 | </para>
|
---|
385 | <indexterm zone="gpm hltest">
|
---|
386 | <primary sortas="b-hltest">hltest</primary>
|
---|
387 | </indexterm>
|
---|
388 | </listitem>
|
---|
389 | </varlistentry>
|
---|
390 |
|
---|
391 | <varlistentry id="mev">
|
---|
392 | <term><command>mev</command></term>
|
---|
393 | <listitem>
|
---|
394 | <para>
|
---|
395 | is a program to report mouse events
|
---|
396 | </para>
|
---|
397 | <indexterm zone="gpm mev">
|
---|
398 | <primary sortas="b-mev">mev</primary>
|
---|
399 | </indexterm>
|
---|
400 | </listitem>
|
---|
401 | </varlistentry>
|
---|
402 |
|
---|
403 | <varlistentry id="mouse-test">
|
---|
404 | <term><command>mouse-test</command></term>
|
---|
405 | <listitem>
|
---|
406 | <para>
|
---|
407 | is a tool for determining the mouse type and device it's
|
---|
408 | attached to
|
---|
409 | </para>
|
---|
410 | <indexterm zone="gpm mouse-test">
|
---|
411 | <primary sortas="b-mouse-test">mouse-test</primary>
|
---|
412 | </indexterm>
|
---|
413 | </listitem>
|
---|
414 | </varlistentry>
|
---|
415 |
|
---|
416 | <varlistentry id="libgpm">
|
---|
417 | <term><filename class="libraryfile">libgpm.so</filename></term>
|
---|
418 | <listitem>
|
---|
419 | <para>
|
---|
420 | contains the API functions to access the
|
---|
421 | <application>GPM</application> daemon
|
---|
422 | </para>
|
---|
423 | <indexterm zone="gpm libgpm">
|
---|
424 | <primary sortas="c-libgpm">libgpm.so</primary>
|
---|
425 | </indexterm>
|
---|
426 | </listitem>
|
---|
427 | </varlistentry>
|
---|
428 |
|
---|
429 | </variablelist>
|
---|
430 |
|
---|
431 | </sect2>
|
---|
432 |
|
---|
433 | </sect1>
|
---|