Luca wrote: > James Richard Tyrer wrote: >> Luca wrote: >> >>> Hi! >>> >>> I have installed kde-3.5.4, xfce4, metacity, gnome-2.14.2 and >>> gnome-2.16.0 and I use kdm as login manager. I created the desktop files >>> for the sessions but I am unable to start gnome-2.16.0. >>> Kde-3.5.4 is installed in /opt/kde-3.5.4 with a symlink /opt/kde >>> pointing to it, gnome-2.14.2 is installed in /opt/gnome-2.14.2 with a >>> symlink /opt/gnome pointing to it, gnome-2.16.0 is installed in >>> /opt/gnome-2.16.0, xfce4 is installed in /usr and metacity is installed >>> in /usr. >>> >>> Since I use to launch dbus-daemon with gnome my gnome-xxx desktop files >>> looks so: >>> gnome-dbus.desktop >>> [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 >>> >>> gnome-2.16.0-dbus.desktop >>> [Desktop Entry] >>> Encoding=UTF-8 >>> Name=GNOME 2.16.0 with D-BUS >>> Comment=GNOME 2.16.0 Desktop with D-BUS support >>> Exec=dbus-launch --exit-with-session /opt/gnome-2.16.0/bin/gnome-session >>> TryExec=/usr/bin/dbus-launch >>> Icon= >>> Type=Application >>> >>> How do I manage to start the different sessions? >>> I also tried to modify /opt/kde-3.5.4/share/config/kdm/Xsession in this way: >>> case $session in >>> "") >>> exec xmessage -center -buttons OK:0 -default OK "Sorry, >>> $DESKTOP_SESSION is no valid session." >>> ;; >>> failsafe) >>> exec xterm -geometry 80x24-0-0 >>> ;; >>> custom) >>> exec $HOME/.xsession >>> ;; >>> default) >>> exec /opt/kde-3.5.4/bin/startkde >>> ;; >>> Gnome-2.14.2) >>> export BINDIR=/opt/gnome-2.14.2/sbin >>> export HOME=$HOME/.gnome-2.14.2 >>> export SBINDIR=/opt/gnome-2.14.2/sbin >>> export LIBEXECDIR=/opt/gnome-2.14.2/lib/gdm >>> export PATH=/bin:/usr/bin:/usr/X11R7/bin:$GNOMEDIR >>> exec /opt/gnome-2.14.2/bin/gnome-session >>> ;; >>> Gnome-2.16.0) >>> export BINDIR=/opt/gnome-2.16.0/sbin >>> export HOME=$HOME/.gnome-2.16.0 >>> export SBINDIR=/opt/gnome-2.16.0/sbin >>> export LIBEXECDIR=/opt/gnome-2.16.0/lib/gdm >>> export PATH=/bin:/usr/bin:/usr/X11R7/bin:$GNOMEDIR >>> exec /opt/gnome-2.16.0/bin/gnome-session >>> ;; >>> *) >>> eval exec "$session" >>> ;; >>> esac >>> exec xmessage -center -buttons OK:0 -default OK "Sorry, cannot execute >>> $session. Check $DESKTOP_SESSION.desktop." >>> >>> Still I am unable to start gnome-2.16.0, and just a note when I start >>> gnome-2.14.2 it seems to load in background some things of gnome-2.16.0, >>> I have two trash icons. >>> >> If you are going to directly execute "gnome-session" the stuff you put >> in the: "gnome-xxx.desktop" is not relevant since it is NOT executed. >> >> I don't think that you want to change HOME and I have no idea if setting >> BINDIR, SBINDIR, & LIBEXECDIR does anything at all except to take up >> space. Stuff in the environment doesn't do any good unless something >> reads it. >> >> What is: GNOMEDIR? IAC, the directory "/opt/gnome-<version>/bin" needs >> to go at the _start_ of the PATH. If there is stuff in: >> "/opt/gnome-<version>/sbin" you might need to add that as well although >> normally, only root uses it. >> >> Then, you have two sets of GNOME libraries. You must use the correct >> ones. To control this, you must set the environment variable >> LD_LIBRARY_PATH. >> >> LD_LIBRARY_PATH=/opt/gnome-<version>/lib >> export LD_LIBRARY_PATH >> >> There are other issues so I would recommend that rather than putting >> this stuff in your "Xsession" script that you write a short script to >> start GNOME -- one script for each version. >> >> I find that to run GNOME that I must set: XDG_CONFIG_DIRS. >> >> > Thanks James I'll try that, however is it possible to export the > variables in the gnome-<version>.desktop files instead of creating a > script to start one or another? In theory, you can execute multiple commands with "Exec=<command line>", however, KDE tends to balk at long command lines in 'desktop' files. Also, you are going to need some punctuation between commands just like on the shell command line. Either: <command 1> && <command 2> or <command 1>: <command 2> I would use the first one in this case (with "&&") since this makes it dependent -- "<command 2> will only execute if "<command 1>" works (i.e. no error code on exit). -- JRT ___________________________________________________ This message is from the kde mailing list. Account management: https://mail.kde.org/mailman/listinfo/kde. Archives: http://lists.kde.org/. More info: http://www.kde.org/faq.html.