Xfce Forum

Sub domains
 

You are not logged in.

#1 2007-02-02 21:26:57

Pindakoe
Member
From: NL
Registered: 2003-11-26
Posts: 116

cannot select Xfce 4 in GDM

I just upgraded from Xfce 4.4RC2 to 4.4.0 final. There was a problem with libxfce4mcs3 (th couldn;t be replaced by libxfce4mcs4 which comes with 4.4.0 final) so I thought after a couple of days running with xfce 4.4.0 using libxfcemcs3 that a clean start would resolve this last detail. Thus: stopped X, removed all xfce-packages and re-installed it. Idea was that this would then automatrically pull in only the newest packages. This worked, but since then I cannot select xfce as a session in GDM -- it defaults to Gnome (default DE of the Mandriva version I have). The only way I can start xfce4 is by booting up in level 3, logon followed by startxfce4.

I have never quite understood how GDM figures out which sessions to offer; files in /etc/X11/dm/Sessions and/or /etc/X11/wmsession.d seem to have something to do with it. These both contain a file with xfce in its name (06Xce4.desktop and 06XFce4 respectively). Per user a file ~/.dmrc exists which has something to do with it as well. I do not understand the roles of these files well.  Anybody who can advise how to correct this? All I want is to logon from GDM and then (usually) start Xfce4 (occasioanlly it would be Gnome).

Offline

#2 2007-02-03 02:19:21

philip
Member
Registered: 2007-01-29
Posts: 2

Re: cannot select Xfce 4 in GDM

The file ${HOME}/.dmrc is specific to the user who owns it. It keeps track of that user's previous session (and, perhaps, other related stuff). But gdm serves all users, so the file you want to play with must be elsewhere.

I have both SuSE 10.2 and Ubuntu 2006.10 running. In both cases, the directory /usr/share/xsessions is the key to everything. Files of the form *.desktop in this directory are read by gdm as it determines which sessions to offer and how to start them. Perhaps your situation could be improved by copying my file xfce4.desktop into the /usr/share/xsessions directory on your machine. Here it is.

[Desktop Entry]
Encoding=UTF-8
Name=Xfce Session
Comment=Use this session to run Xfce as your desktop environment
Exec=startxfce4
Icon=
Type=Application

Edits are possible: my two distros use the text you put in the "Name" field to populate the gdm session chooser. Ubuntu prefers to put the full path of the startxfce4 command in the "Exec" line, and it also fills in the assignment for an "Icon". All the other *.desktop files on my SuSE setup say "Type=XSession", but this file works as-is for me.

Good luck. Drop a line back here if this does the job, or if you succeed after a little more fiddling.

Offline

#3 2007-02-03 08:31:32

Pindakoe
Member
From: NL
Registered: 2003-11-26
Posts: 116

Re: cannot select Xfce 4 in GDM

Many thanks for the response. Your data helped me choose on one thing, even though Mandriva is different from both Ubuntu and Suse in this respect: /usr/share/xsession (or variations on that in capitalisation) do not exist. Based on your description I think that Mandriva uses /etc/X11/dm/Sessions for the same purpose. Mine has a file '06XFce4.desktop' with nearly identical content to yours -- the differences are cosmetic only (I think after studying the syntax for these files at freedesktop.org) -- Mandriva also spells out the full path (like Ubuntu); type is Application (like Suse).

I have in the meantime made some progresss. GDM showed 5 sessions (Last session, Default, foo, foo, foo). From freedesktop I learnt that syntax error in .desktop files cause it to be interpreted as 'foo'. I have selected foo #2 and this indeed mapped to 06Xfce4 after which all worked as before.
I wil go through the .desktop files with a fine comb (it shouldn't be too hard to find a syntax error in a file of 6 lines I hope) and may be post at Mandriva for explanation of how they start xsessions.

Offline

#4 2007-02-03 18:34:51

philip
Member
Registered: 2007-01-29
Posts: 2

Re: cannot select Xfce 4 in GDM

I found it useful when debugging to add some distinctive text to the "name" field of each .desktop file. Then I could be sure the file I was inspecting was actually  the one GDM was reading.

Gentoo has almost the same path to session files as you quote for Mandrake, except that "gdm" replaces "dm" at an intermediate point. In case this is of any interest, I quote my file /etc/X11/gdm/Sessions/XFce4 below. It has special inserts for Mandrake that I don't understand -- but maybe you will.

#!/bin/sh
########################################################################
#
# XFce 4file for GDM.  Usually in /etc/X11/gdm/Sessions.
#
# Add support for XIM; Modified by Babyfai Cheung.  2002/03/10 
########################################################################
## Launch an XIM input server if needed

# This's for RedHat and Slackware
for i in /etc/X11/xinit/xinitrc.d/* ; do
    if [ -x "$i" ]; then
        . "$i"
    fi
done

# This's for Mandrake
if [ -x /etc/X11/xinit/XIM ]; then
   . /etc/X11/xinit/XIM
fi

# Option ignoreABI added by me, 2007-01-09:
exec /usr/bin/startxfce4 -ignoreABI

Do report back when you get everything working just right. It will help others.

Good luck! - Philip

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.013 seconds, 12 queries executed - Memory usage: 533.57 KiB (Peak: 534.2 KiB) ]