source: general/sysutils/dbus.xml@ 371ff30

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 371ff30 was 371ff30, checked in by DJ Lucas <dj@…>, 18 years ago

several cleanups-Xorg7 related

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

  • Property mode set to 100644
File size: 16.1 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY dbus-download-http "http://dbus.freedesktop.org/releases/dbus-&dbus-version;.tar.gz">
8 <!ENTITY dbus-download-ftp "ftp://ftp.fu-berlin.de/unix/linux/mirrors/gentoo/distfiles/dbus-&dbus-version;.tar.gz">
9 <!ENTITY dbus-md5sum "1addd5b600a8a4550766005d1f59401b">
10 <!ENTITY dbus-size "1.6 MB">
11 <!ENTITY dbus-buildsize "34.6 MB">
12 <!ENTITY dbus-time "0.9 SBU">
13]>
14
15<sect1 id="dbus" xreflabel="D-BUS-&dbus-version;">
16 <?dbhtml filename="dbus.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 <keywordset>
22 <keyword role="package">dbus-&dbus-version;.tar</keyword>
23 <keyword role="ftpdir">dbus</keyword>
24 </keywordset>
25 </sect1info>
26
27 <title>D-BUS-&dbus-version;</title>
28
29 <indexterm zone="dbus">
30 <primary sortas="a-D-BUS">D-BUS</primary>
31 </indexterm>
32
33 <sect2 role="package">
34 <title>Introduction to D-BUS</title>
35
36 <para><application>D-BUS</application> is a message bus system, a simple
37 way for applications to talk to one another.
38 <application>D-BUS</application> supplies both a system daemon (for events
39 such as <quote>new hardware device added</quote> or <quote>printer queue
40 changed</quote>) and a per-user-login-session daemon (for general IPC needs
41 among user applications). Also, the message bus is built on top of a
42 general one-to-one message passing framework, which can be used by any two
43 applications to communicate directly (without going through the message bus
44 daemon).</para>
45
46 <bridgehead renderas="sect3">Package Information</bridgehead>
47 <itemizedlist spacing="compact">
48 <listitem>
49 <para>Download (HTTP): <ulink url="&dbus-download-http;"/></para>
50 </listitem>
51 <listitem>
52 <para>Download (FTP): <ulink url="&dbus-download-ftp;"/></para>
53 </listitem>
54 <listitem>
55 <para>Download MD5 sum: &dbus-md5sum;</para>
56 </listitem>
57 <listitem>
58 <para>Download size: &dbus-size;</para>
59 </listitem>
60 <listitem>
61 <para>Estimated disk space required: &dbus-buildsize;</para>
62 </listitem>
63 <listitem>
64 <para>Estimated build time: &dbus-time;</para>
65 </listitem>
66 </itemizedlist>
67
68 <bridgehead renderas="sect3">D-BUS Dependencies</bridgehead>
69
70 <bridgehead renderas="sect4">Optional</bridgehead>
71 <para role="optional"><xref linkend="pkgconfig"/>,
72 <xref linkend="expat"/> or <xref linkend="libxml2"/>,
73 <xref linkend="glib2"/>,
74 <xref linkend="gtk2"/>,
75 <xref linkend="qt"/>,
76 X (<xref linkend="xorg"/>, <xref linkend="xorg7"/>, or
77 <xref linkend="xfree86"/>),
78 <xref linkend="gcc"/> (for the Java compiler and tools),
79 <ulink url="http://nz.cosc.canterbury.ac.nz/~greg/python/Pyrex/">Pyrex</ulink>
80 (requires <xref linkend="python"/>),
81 <ulink url="http://go-mono.org">Mono</ulink> (and
82 <ulink url="http://www.mono-project.com/GtkSharp">GtkSharp-1.0.x</ulink>),
83 <xref linkend="doxygen"/> and
84 <ulink url="http://cyberelk.net/tim/xmlto/">xmlto</ulink></para>
85
86 <bridgehead renderas="sect4" id="hal-requirements"
87 xreflabel="HAL Requirements">HAL Requirements</bridgehead>
88 <para><xref linkend="glib2"/> must be installed before you begin building
89 <application>D-BUS</application> if you plan on installing
90 <xref linkend="hal"/>. <application>GLib</application> is required to build
91 the <filename class='libraryfile'>libdbus-glib</filename> library, which is
92 required by the <application>HAL</application> daemon. Additionally, if you
93 desire to use the <xref linkend="hal-device-manager"/> program,
94 <ulink url="http://nz.cosc.canterbury.ac.nz/~greg/python/Pyrex/">
95 Pyrex</ulink> must be installed before you begin building
96 <application>D-BUS</application> as the <application>D-BUS</application>
97 <application>Python</application> bindings are required. You will also
98 need to remove the <parameter>--disable-python</parameter> parameter from
99 the <command>configure</command> command in the instructions below.</para>
100
101 </sect2>
102
103 <sect2 role="kernel" id='dbus-kernel'>
104 <title>Kernel Configuration</title>
105
106 <para>Ensure the following option is enabled in the kernel configuration
107 and recompile the kernel if necessary:</para>
108
109<screen><literal>General Setup
110 System V IPC</literal></screen>
111
112 <indexterm zone="dbus dbus-kernel">
113 <primary sortas="d-dbus">dbus</primary>
114 </indexterm>
115
116 </sect2>
117
118 <sect2 role="installation">
119 <title>Installation of D-BUS</title>
120
121 <para>As the <systemitem class="username">root</systemitem> user, create a
122 system user and group to handle the system message bus activity:</para>
123
124<screen role="root"><userinput>groupadd -g 18 messagebus &amp;&amp;
125useradd -c "D-BUS Message Daemon User" -d /dev/null \
126 -u 18 -g messagebus -s /bin/false messagebus</userinput></screen>
127
128 <para>Install <application>D-BUS</application> by running the following
129 commands (you may wish to review the output from
130 <command>./configure --help</command> first and add any desired parameters
131 to the <command>configure</command> command shown below):</para>
132
133<screen><userinput>sed -i 's/= jar/= fastjar/' gcj/Makefile.in &amp;&amp;
134./configure --prefix=/usr \
135 --sysconfdir=/etc \
136 --localstatedir=/var \
137 --disable-python &amp;&amp;
138make</userinput></screen>
139
140 <para>This package does not come with a test suite.</para>
141
142 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
143
144<screen role="root"><userinput>make install &amp;&amp;
145install -v -m755 -d /usr/share/doc/dbus-0.50 &amp;&amp;
146install -v -m644 doc/{TODO,*.{dtd,xml,xsl,html,txt,c}} \
147 /usr/share/doc/dbus-0.50</userinput></screen>
148
149 </sect2>
150
151 <sect2 role="commands">
152 <title>Command Explanations</title>
153
154 <para><command>sed -i 's/= jar/= fastjar/' gcj/Makefile.in</command>:
155 The <application>GCC</application>-&gcc-version; compiler installation
156 installs a command named <command>fastjar</command> to create Java
157 <filename class='extension'>.jar</filename> files instead of
158 <command>jar</command>. This <command>sed</command> command changes the
159 <filename>Makefile</filename> to use the appropriate command so the build
160 doesn't fail if you passed the <option>--enable-gcj</option> option to
161 the <command>configure</command> command.</para>
162
163 <para><parameter>--localstatedir=/var</parameter>: This parameter causes
164 the daemon PID file to be created in
165 <filename class="directory">/var/run/dbus</filename> instead of
166 <filename class="directory">/usr/var/run/dbus</filename>.</para>
167
168 <para><parameter>--disable-python</parameter>: This parameter is required
169 if <application>Python</application> is not installed. Remove the parameter
170 if <application>Python</application> (and <application>Pyrex</application>)
171 is installed and you wish to build the
172 <application>Python</application> bindings.</para>
173
174 </sect2>
175
176 <sect2 role="configuration">
177 <title>Configuring dbus</title>
178
179 <sect3 id="dbus-config">
180 <title>Config Files</title>
181 <para><filename>/etc/dbus-1/session.conf</filename>,
182 <filename>/etc/dbus-1/system.conf</filename> and
183 <filename>/etc/system.d/*</filename></para>
184
185 <indexterm zone="dbus dbus-config">
186 <primary sortas="e-etc-dbus-1-session.conf">/etc/dbus-1/session.conf</primary>
187 </indexterm>
188
189 <indexterm zone="dbus dbus-config">
190 <primary sortas="e-etc-dbus-1/system.conf">/etc/dbus-1/system.conf</primary>
191 </indexterm>
192
193 <indexterm zone="dbus dbus-config">
194 <primary sortas="e-etc-system.d-star">/etc/system.d/*</primary>
195 </indexterm>
196
197 </sect3>
198
199 <sect3><title>Configuration Information</title>
200
201 <para>The configuration files listed above should probably not be
202 modified. If changes are required, you should create
203 <filename>/etc/dbus-1/session-local.conf</filename> and/or
204 <filename>/etc/dbus-1/system-local.conf</filename> and make any
205 desired changes to these files.</para>
206
207 </sect3>
208
209 <sect3 id="dbus-init">
210 <title>Boot Script</title>
211
212 <para>To automatically start <command>dbus-daemon</command> when the
213 system is rebooted, install the
214 <filename>/etc/rc.d/init.d/dbus</filename> bootscript from the
215 <xref linkend="bootscripts"/> package.</para>
216
217 <indexterm zone="dbus dbus-init">
218 <primary sortas="f-dbus">dbus</primary>
219 </indexterm>
220
221<screen role="root"><userinput>make install-dbus</userinput></screen>
222
223 <para>Note that this boot script only starts the system-wide
224 <application>D-BUS</application> daemon. Each user requiring access to
225 <application>D-BUS</application> services will also need to run a
226 session daemon as well. There are many methods you can use to start a
227 session daemon using the <command>dbus-launch</command> command. Review
228 the <command>dbus-launch</command> man page for details about the
229 available parameters and options. Here are some suggestions and
230 examples:</para>
231
232 <itemizedlist spacing="compact">
233 <listitem>
234 <para>Add <command>dbus-launch</command> to the line in the
235 <filename>~/.xinitrc</filename> file that starts your graphical
236 desktop environment as shown in <xref linkend="gnome-config"/>.</para>
237 </listitem>
238 <listitem>
239 <para>If you use <command>xdm</command> or some other display manager
240 that calls the <filename>~/.xsession</filename> file, you can add
241 <command>dbus-launch</command> to the line in your
242 <filename>~/.xsession</filename> file that starts your graphical
243 desktop environment. The syntax would be similar to the example in
244 the <filename>~/.xinitrc</filename> file.</para>
245 </listitem>
246 <listitem>
247 <para>If you use <command>gdm</command> or some other display manager
248 that utilizes custom files to initiate sessions, use the example in
249 <xref linkend="gdm-config-dbus"/> of the
250 <application>GDM</application> instructions to create a file
251 containing <command>dbus-launch</command>.</para>
252 </listitem>
253 <listitem>
254 <para>The examples shown previously use
255 <command>dbus-launch</command> to specify a program to be run. This
256 has the benefit (when also using the
257 <parameter>--exit-with-session</parameter> parameter) of stopping the
258 session daemon when the specified program is stopped. You can also
259 start the session daemon in your system or personal startup scripts
260 by adding the following lines:</para>
261
262<screen><userinput><literal># Start the D-BUS session daemon
263eval `dbus-launch`
264export DBUS_SESSION_BUS_ADDRESS</literal></userinput></screen>
265
266 <para>This method will not stop the session daemon when you exit
267 your shell, therefore you should add the following line to your
268 <filename>~/.bash_logout</filename> file:</para>
269
270<screen><userinput><literal># Kill the D-BUS session daemon
271kill $DBUS_SESSION_BUS_PID</literal></userinput></screen>
272 </listitem>
273 <listitem>
274 <para>If you use <application>Linux-PAM</application>, you can review
275 the <ulink
276 url="&hints-root;/downloads/files/execute-session-scripts-using-pam.txt">
277 Execute Session Scripts Using PAM</ulink> hint to see if it would work
278 for you.</para>
279 </listitem>
280 </itemizedlist>
281
282 </sect3>
283
284 </sect2>
285
286 <sect2 role="content">
287 <title>Contents</title>
288
289 <segmentedlist>
290 <segtitle>Installed Programs</segtitle>
291 <segtitle>Installed Libraries</segtitle>
292 <segtitle>Installed Directories</segtitle>
293
294 <seglistitem>
295 <seg>dbus-binding-tool, dbus-cleanup-sockets, dbus-daemon, dbus-launch,
296 dbus-monitor, dbus-send and dbus-viewer</seg>
297 <seg>libdbus-1.[so,a] and optionally, dbus-1.jar, libdbus-gcj-1.[so,a],
298 libdbus-glib-1.[so,a], libdbus-qt-1.[so,a] and
299 <application>Python</application> modules</seg>
300 <seg>/etc/dbus-1, /usr/include/dbus-1.0, /usr/lib/dbus-1.0,
301 /usr/lib/python2.4/site-packages/dbus, /usr/share/dbus-1,
302 /usr/share/doc/dbus-&dbus-version; and /var/run/dbus</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="dbus-binding-tool">
312 <term><command>dbus-binding-tool</command></term>
313 <listitem>
314 <para>is used to create header files from
315 <application>GLib</application> object files.</para>
316 <indexterm zone="dbus dbus-binding-tool">
317 <primary sortas="b-dbus-binding-tool">dbus-binding-tool</primary>
318 </indexterm>
319 </listitem>
320 </varlistentry>
321
322 <varlistentry id="dbus-cleanup-sockets">
323 <term><command>dbus-cleanup-sockets</command></term>
324 <listitem>
325 <para>is used to clean up leftover sockets in a directory.</para>
326 <indexterm zone="dbus dbus-cleanup-sockets">
327 <primary sortas="b-dbus-cleanup-sockets">dbus-cleanup-sockets</primary>
328 </indexterm>
329 </listitem>
330 </varlistentry>
331
332 <varlistentry id="dbus-daemon">
333 <term><command>dbus-daemon</command></term>
334 <listitem>
335 <para>is the <application>D-BUS</application> message bus
336 daemon.</para>
337 <indexterm zone="dbus dbus-daemon">
338 <primary sortas="b-dbus-daemon">dbus-daemon</primary>
339 </indexterm>
340 </listitem>
341 </varlistentry>
342
343 <varlistentry id="dbus-launch">
344 <term><command>dbus-launch</command></term>
345 <listitem>
346 <para>is used to start <command>dbus-daemon</command> from a shell
347 script. It would normally be called from a user's login
348 scripts.</para>
349 <indexterm zone="dbus dbus-launch">
350 <primary sortas="b-dbus-launch">dbus-launch</primary>
351 </indexterm>
352 </listitem>
353 </varlistentry>
354
355 <varlistentry id="dbus-monitor">
356 <term><command>dbus-monitor</command></term>
357 <listitem>
358 <para>is used to monitor messages going through a
359 <application>D-BUS</application> message bus.</para>
360 <indexterm zone="dbus dbus-monitor">
361 <primary sortas="b-dbus-monitor">dbus-monitor</primary>
362 </indexterm>
363 </listitem>
364 </varlistentry>
365
366 <varlistentry id="dbus-send">
367 <term><command>dbus-send</command></term>
368 <listitem>
369 <para>is used to send a message to a <application>D-BUS</application>
370 message bus.</para>
371 <indexterm zone="dbus dbus-send">
372 <primary sortas="b-dbus-send">dbus-send</primary>
373 </indexterm>
374 </listitem>
375 </varlistentry>
376
377 <varlistentry id="dbus-viewer">
378 <term><command>dbus-viewer</command></term>
379 <listitem>
380 <para>is a graphical <application>D-BUS</application> frontend
381 utility.</para>
382 <indexterm zone="dbus dbus-viewer">
383 <primary sortas="b-dbus-viewer">dbus-viewer</primary>
384 </indexterm>
385 </listitem>
386 </varlistentry>
387
388 <varlistentry id="libdbus-1">
389 <term><filename class='libraryfile'>libdbus-1.[so,a]</filename></term>
390 <listitem>
391 <para>contains the API functions used by the
392 <application>D-BUS</application> message daemon.
393 <application>D-BUS</application> is first a library that provides
394 one-to-one communication between any two applications;
395 <command>dbus-daemon</command> is an application that uses this
396 library to implement a message bus daemon.</para>
397 <indexterm zone="dbus libdbus-1">
398 <primary sortas="c-libdbus-1">libdbus-1.[so,a]</primary>
399 </indexterm>
400 </listitem>
401 </varlistentry>
402
403 </variablelist>
404
405 </sect2>
406
407</sect1>
Note: See TracBrowser for help on using the repository browser.