source: general/sysutils/gpm.xml@ 110854d

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 110854d was 110854d, checked in by Pierre Labastie <pieere@…>, 4 years ago

Fix systemd and gpm for gcc 10

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@23087 af4574ff-66df-0310-9fd7-8a98e5e911e0

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