Author: randy Date: 2005-11-19 16:59:27 -0700 (Sat, 19 Nov 2005) New Revision: 5283
Modified: trunk/BOOK/general.ent trunk/BOOK/general/sysutils/dbus.xml trunk/BOOK/gnome/add/gdm.xml trunk/BOOK/gnome/core/config.xml trunk/BOOK/introduction/welcome/changelog.xml Log: Added notes to start a D-BUS session daemon to the D-BUS, GDM and GNOME Configuration instructions Modified: trunk/BOOK/general/sysutils/dbus.xml =================================================================== --- trunk/BOOK/general/sysutils/dbus.xml 2005-11-19 23:53:32 UTC (rev 5282) +++ trunk/BOOK/general/sysutils/dbus.xml 2005-11-19 23:59:27 UTC (rev 5283) @@ -5,7 +5,7 @@ %general-entities; <!ENTITY dbus-download-http "http://dbus.freedesktop.org/releases/dbus-&dbus-version;.tar.gz"> - <!ENTITY dbus-download-ftp " "> + <!ENTITY dbus-download-ftp "ftp://ftp.fu-berlin.de/unix/linux/mirrors/gentoo/distfiles/dbus-&dbus-version;.tar.gz"> <!ENTITY dbus-md5sum "1addd5b600a8a4550766005d1f59401b"> <!ENTITY dbus-size "1.6 MB"> <!ENTITY dbus-buildsize "34.6 MB"> @@ -181,6 +181,65 @@ <screen role="root"><userinput>make install-dbus</userinput></screen> + <para>Note that this boot script only starts the system-wide + <application>D-BUS</application> daemon. Each user requiring access to + <application>D-BUS</application> services will also need to run a + session daemon as well. There are many methods you can use to start a + session daemon using the <command>dbus-launch</command> command. Review + the <command>dbus-launch</command> man page for details about the + available parameters and options. Here are some suggestions and + examples:</para> + + <itemizedlist spacing="compact"> + <listitem> + <para>Add <command>dbus-launch</command> to the line in the + <filename>~/.xinitrc</filename> file that starts your graphical + desktop environment as shown in <xref linkend="gnome-config"/>.</para> + </listitem> + <listitem> + <para>If you use <command>xdm</command> or some other display manager + that calls the <filename>~/.xsession</filename> file, you can add + <command>dbus-launch</command> to the line in your + <filename>~/.xsession</filename> file that starts your graphical + desktop environment. The syntax would be similar to the example in + the <filename>~/.xinitrc</filename> file.</para> + </listitem> + <listitem> + <para>If you use <command>gdm</command> or some other display manager + that utilizes custom files to initiate sessions, use the example in + <xref linkend="gdm-config-dbus"/> of the + <application>GDM</application> instructions to create a file + containing <command>dbus-launch</command>.</para> + </listitem> + <listitem> + <para>The examples shown previously use + <command>dbus-launch</command> to specify a program to be run. This + has the benefit (when also using the + <parameter>--exit-with-session</parameter> parameter) of stopping the + session daemon when the specified program is stopped. You can also + start the session daemon in your system or personal startup scripts + by adding the following lines:</para> + +<screen><userinput><literal># Start the D-BUS session daemon +eval `dbus-launch` +export DBUS_SESSION_BUS_ADDRESS</literal></userinput></screen> + + <para>This method will not stop the session daemon when you exit + your shell, therefore you should add the following line to your + <filename>~/.bash_logout</filename> file:</para> + +<screen><userinput><literal># Kill the D-BUS session daemon +kill $DBUS_SESSION_BUS_PID</literal></userinput></screen> + </listitem> + <listitem> + <para>If you use <application>Linux-PAM</application>, you can review + the <ulink + url="&hints-root;/downloads/files/execute-session-scripts-using-pam.txt"> + Execute Session Scripts Using PAM</ulink> hint to see if it would work + for you.</para> + </listitem> + </itemizedlist> + </sect3> </sect2> Modified: trunk/BOOK/general.ent =================================================================== --- trunk/BOOK/general.ent 2005-11-19 23:53:32 UTC (rev 5282) +++ trunk/BOOK/general.ent 2005-11-19 23:59:27 UTC (rev 5283) @@ -1,4 +1,4 @@ -<!ENTITY day "18"> +<!ENTITY day "19"> <!ENTITY month "11"> <!ENTITY year "2005"> <!ENTITY version "svn-&year;&month;&day;"> Modified: trunk/BOOK/gnome/add/gdm.xml =================================================================== --- trunk/BOOK/gnome/add/gdm.xml 2005-11-19 23:53:32 UTC (rev 5282) +++ trunk/BOOK/gnome/add/gdm.xml 2005-11-19 23:59:27 UTC (rev 5283) @@ -180,9 +180,34 @@ sortas="e-etc-pam.d-gdm-autologin">/etc/pam.d/gdm-autologin</primary> </indexterm> - <para><command>gdm</command> can be tested by executing it from a - <systemitem class="username">root</systemitem> console.</para> + <para id="gdm-config-dbus">If you have <application>D-BUS</application> + installed and you want to start the session + <application>D-BUS</application> daemon when you start the GNOME desktop + environment using <command>gdm</command>, you'll need to create a new + Xsession file. Create the file using the following command as the root + user.</para> +<screen role="root"><userinput>cat > $GNOME_PREFIX/share/xsessions/gnome-dbus.desktop << "EOF" +<literal>[Desktop Entry] +Encoding=UTF-8 +Name=GNOME with D-BUS +Comment=GNOME Desktop with D-BUS support +Exec=dbus-launch --exit-with-session gnome-session +TryExec=/usr/bin/dbus-launch +Icon= +Type=Application</literal> + +EOF</userinput></screen> + + <para>Choose this session using the session selection dialog on the + display manager login screen. You also have the opportunity to make this + your default session.</para> + + <para><command>gdm</command> can be tested by executing it as the + <systemitem class="username">root</systemitem> user. Use the + <command>gdm-stop</command> command if you wish to stop the display + manager.</para> + </sect3> <sect3 id="gdm-init"> @@ -193,9 +218,10 @@ <xref linkend="intro-important-bootscripts"/> package. If your <envar>GNOME_PREFIX</envar> environment variable is anything other than <filename class='directory'>/usr</filename> or - <filename class='directory'>/opt/gnome-2.10</filename>, you will need to - modify the <envar>PATH</envar> statement in the script to include the - path where you have <application>GNOME</application> installed.</para> + <filename class='directory'>/opt/gnome-&gnome-version;</filename>, you + will need to modify the <envar>PATH</envar> statement in the script to + include the path where you have <application>GNOME</application> + installed.</para> <indexterm zone="gdm gdm-init"> <primary sortas="f-gdm">gdm</primary> Modified: trunk/BOOK/gnome/core/config.xml =================================================================== --- trunk/BOOK/gnome/core/config.xml 2005-11-19 23:53:32 UTC (rev 5282) +++ trunk/BOOK/gnome/core/config.xml 2005-11-19 23:59:27 UTC (rev 5283) @@ -26,7 +26,7 @@ of your <application>GNOME</application> session. If you wish to start the daemon here, use the following command instead of the one shown above:</para> -<screen><userinput>echo "exec dbus-launch --sh-syntax --exit-with-session gnome-session" >> ~/.xinitrc</userinput></screen> +<screen><userinput>echo "exec dbus-launch --exit-with-session gnome-session" >> ~/.xinitrc</userinput></screen> <note> <para>Check the <filename>~/.xinitrc</filename> file and ensure you have Modified: trunk/BOOK/introduction/welcome/changelog.xml =================================================================== --- trunk/BOOK/introduction/welcome/changelog.xml 2005-11-19 23:53:32 UTC (rev 5282) +++ trunk/BOOK/introduction/welcome/changelog.xml 2005-11-19 23:59:27 UTC (rev 5283) @@ -42,6 +42,16 @@ --> <listitem> + <para>November 19th, 2005</para> + <itemizedlist> + <listitem> + <para>[randy] - Added notes to start a D-BUS session daemon to the + D-BUS, GDM and GNOME Configuration instructions.</para> + </listitem> + </itemizedlist> + </listitem> + + <listitem> <para>November 18th, 2005</para> <itemizedlist> <listitem> -- http://linuxfromscratch.org/mailman/listinfo/blfs-book FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
