diff options
author | Matthieu Herrb <matthieu@cvs.openbsd.org> | 2012-08-04 20:41:43 +0000 |
---|---|---|
committer | Matthieu Herrb <matthieu@cvs.openbsd.org> | 2012-08-04 20:41:43 +0000 |
commit | 6248002cedd900967ceaeafc7e587c864e0aa01c (patch) | |
tree | b0c3904b758050d80bdd18d0d4f8adaa5b4e31ba | |
parent | 3ca201b3f1d8839b399b35945b1d2f3063636b25 (diff) |
If dbus is installed, start the daemon as part of the X session.
That will help applications that depend on dbus beeing started.
With ajacoutot@.
-rw-r--r-- | app/xdm/config/Xsession.cpp | 6 | ||||
-rw-r--r-- | app/xinit/xinitrc.cpp | 7 |
2 files changed, 11 insertions, 2 deletions
diff --git a/app/xdm/config/Xsession.cpp b/app/xdm/config/Xsession.cpp index a840cb4bb..a22a849f6 100644 --- a/app/xdm/config/Xsession.cpp +++ b/app/xdm/config/Xsession.cpp @@ -1,6 +1,6 @@ XCOMM!SHELL_CMD XCOMM -XCOMM $OpenBSD: Xsession.cpp,v 1.9 2011/12/03 13:46:00 matthieu Exp $ +XCOMM $OpenBSD: Xsession.cpp,v 1.10 2012/08/04 20:41:42 matthieu Exp $ XCOMM redirect errors to a file in user's home directory if we can @@ -101,6 +101,10 @@ else exec `eval $XDESKTOP` } #endif + if [ -x /usr/local/bin/dbus-launch \ + -a -z "${DBUS_SESSION_BUS_ADDRESS}" ]; then + eval `dbus-launch --sh-syntax --exit-with-session` + fi BINDIR/xterm & BINDIR/fvwm fi diff --git a/app/xinit/xinitrc.cpp b/app/xinit/xinitrc.cpp index 5f0f5cfcf..bea4640c5 100644 --- a/app/xinit/xinitrc.cpp +++ b/app/xinit/xinitrc.cpp @@ -1,5 +1,5 @@ XCOMM!SHELL_CMD -XCOMM $OpenBSD: xinitrc.cpp,v 1.6 2011/03/19 15:40:02 matthieu Exp $ +XCOMM $OpenBSD: xinitrc.cpp,v 1.7 2012/08/04 20:41:42 matthieu Exp $ userresources=$HOME/.Xresources usermodmap=$HOME/.Xmodmap @@ -51,6 +51,11 @@ then ssh-add < /dev/null fi +XCOMM if dbus is installed, start its daemon +if test -x /usr/local/bin/dbus-launch -a -z "$DBUS_SESSION_BUS_ADDRESS" ; then + eval `dbus-launch --sh-syntax --exit-with-session` +fi + XCOMM start some nice programs XCLOCK -geometry 50x50-1+1 & |