Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 201535 - x11-wm/fluxbox does not provide a proper X11 Session file
Summary: x11-wm/fluxbox does not provide a proper X11 Session file
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Jim Ramsay (lack) (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on: 201625
Blocks:
  Show dependency tree
 
Reported: 2007-12-06 22:59 UTC by Doug Goldstein (RETIRED)
Modified: 2009-06-25 12:50 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
/etc/X11/Sessions/fluxbox (20071207_etc_X11_Sessions_fluxbox,1.96 KB, text/plain)
2007-12-07 23:18 UTC, Robin Johnson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Doug Goldstein (RETIRED) gentoo-dev 2007-12-06 22:59:36 UTC
The Session file that fluxbox provides is inadequate to start up an X session properly. At the minimum the following is missing:


# run all system xinitrc shell scripts.
if [ -d /etc/X11/xinit/xinitrc.d ]; then
    for i in /etc/X11/xinit/xinitrc.d/* ; do
        if [ -x "$i" ]; then
            . "$i"
        fi
    done
fi

Take a look at /etc/X11/Sessions/Xsession for some more examples.
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2007-12-06 23:42:26 UTC
Cardoe: just glancing at /etc/X11/Sessions/Xsession - it doesn't do anything with xinitrc.d either.
Comment 2 Doug Goldstein (RETIRED) gentoo-dev 2007-12-07 14:31:43 UTC
Right. That script is wrong as well. Only reason that hasn't been caught is most people don't use startx + twm for anything but testing.
Comment 3 Jim Ramsay (lack) (RETIRED) gentoo-dev 2007-12-07 14:42:11 UTC
I suppose you mean /etc/X11/Sessions/fluxbox and not
/usr/share/xsessions/fluxbox.desktop

But shouldn't this be the job of xdm or the 'startx' script?

Comment 4 Doug Goldstein (RETIRED) gentoo-dev 2007-12-07 14:47:01 UTC
It's provided by /etc/X11/Sessions/Gnome, you can check with KDE users how it's provided for them.

Granted, /etc/X11/gdm/Xsession provides it as well, so if you were to use gdm to login to fluxbox it would work for you.
Comment 5 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2007-12-07 23:16:10 UTC
Under /etc/X11/Sessions/, Gnome and Xsession are almost identical, differing as follows:
Xsession: loads xterm, errfile has 'xsession' in the name, cleans up after xbanner, tries in order to find what to start: $HOME/.xsession:$HOME/.Xclients:/etc/X11/xinit/Xclients:/etc/X11/Xclients:xsm
Gnome: starts an ssh-agent if none already exist, reads /etc/X11/xinit/xinitrc.d, tries in order to find what to start: $HOME/.gnomerc:/etc/X11/gdm/gnomerc:gnome-session

KDE calls /usr/kde/3.5/bin/startkde, which is radically different from the Gnome and Xsession ones.

However, the sparseness of the fluxbox init explains why Xresources/Xmodmap/Xkbmap seemed to be ignored sometimes.

I'll attach a new /etc/X11/Sessions/fluxbox shortly.

Comment 6 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2007-12-07 23:18:31 UTC
Created attachment 137979 [details]
/etc/X11/Sessions/fluxbox

New script for the fluxbox session start. Based on Xsession and Gnome session scripts. Untested still.
Comment 7 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2007-12-07 23:24:28 UTC
while doing this, I noticed a bug in the Gnome+Xsession scripts, so I filed bug #201625 for them to fix up their XkbSymbols loading - it's fixed in my attached script anyway.
Comment 8 Jim Ramsay (lack) (RETIRED) gentoo-dev 2007-12-08 03:36:06 UTC
Thanks very much for the patch, but this really seems like a lot of code duplication, especially if the only difference between this script and the Xsession and Gnome ones is the last line.

Do we really want to maintain these all separately when it could be done somewhere more central?

For example, have a common /etc/X11/misc/xession.sh that I (and other sessions) could just source before calling 'exec startfluxbox'?
Comment 9 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2007-12-08 04:17:54 UTC
I'm in favour of a merge myself, but I posted the separate version because following the past history of Xsession was very hard. It appears to have fractionated and forked many times, and then each gotten different changes along the way.

Maybe dberkholz can chime in with a plan to rationalize all of them.

gentoo-x86/gnome-base/gnome-session/files/Gnome - last change 2002-06-02
Xsession - originally part of x11-base/xfree, but bounced around many places in CVS - additionally, there is an outdated copy installed into /usr/$libdir/X11/xdm/

Here's a list of every one that ever existed in the tree, ordered by when they were last touched.
 Dec 15  2005 x11-apps/xdm/files/Xsession,v
 Dec 15  2005 x11-apps/xinit/files/Xsession,v
 Nov 16  2005 gnome-base/gdm/files/2.6.0/Attic/Xsession,v
 Sep 12  2005 gnome-base/gdm/files/2.6.0-openpam/Attic/Xsession,v
 Jun  5  2005 gnome-base/gdm/files/2.4.4/Attic/Xsession,v
 Jan  3  2005 x11-base/xfree/files/4.3.0/Attic/Xsession,v
 Jan  3  2005 x11-base/xfree/files/4.3.0/Sessions/Attic/Xsession,v
 Jan 27  2004 x11-base/xfree/files/4.2.1-r2/Attic/Xsession,v
 Jan 27  2004 x11-base/xfree/files/4.2.1-r2/Sessions/Attic/Xsession,v
 Dec 14  2003 x11-base/xfree/files/4.1.0-r6/Attic/Xsession,v
 Dec 14  2003 x11-base/xfree/files/4.2.0-r12/Attic/Xsession,v
 Dec 14  2003 x11-base/xfree/files/4.2.0-r12/Sessions/Attic/Xsession,v
 Aug 29  2003 x11-base/xfree/files/4.3.99.8/Sessions/Attic/Xsession,v
 Aug 28  2003 x11-base/xfree/files/4.3.99.8/Attic/Xsession,v
 May 20  2003 x11-base/xfree/files/4.2.1/Attic/Xsession,v
 May 20  2003 x11-base/xfree/files/4.2.1/Sessions/Attic/Xsession,v
 May 20  2003 x11-base/xfree/files/4.2.1-r1/Attic/Xsession,v
 May 20  2003 x11-base/xfree/files/4.2.1-r1/Sessions/Attic/Xsession,v
 Mar 10  2003 x11-base/xfree/files/4.2.99.902/Attic/Xsession,v
 Mar 10  2003 x11-base/xfree/files/4.2.99.902/Sessions/Attic/Xsession,v
 Feb 28  2003 x11-base/xfree/files/4.2.99.4/Attic/Xsession,v
 Feb 28  2003 x11-base/xfree/files/4.2.99.4/Sessions/Attic/Xsession,v
 Feb  2  2003 x11-base/xfree/files/4.2.99.3-r2/Attic/Xsession,v
 Feb  2  2003 x11-base/xfree/files/4.2.99.3-r2/Sessions/Attic/Xsession,v
 Jan 16  2003 x11-base/xfree/files/4.2.99.3-r1/Attic/Xsession,v
 Jan 16  2003 x11-base/xfree/files/4.2.99.3-r1/Sessions/Attic/Xsession,v
 Dec 26  2002 x11-base/xfree/files/4.2.99.3/Sessions/Attic/Xsession,v
 Dec 26  2002 x11-base/xfree/files/4.2.99.3/Attic/Xsession,v
 Dec  7  2002 x11-base/xfree/files/4.2.99/Attic/Xsession,v
 Dec  7  2002 x11-base/xfree/files/4.2.99/Sessions/Attic/Xsession,v
 Sep  8  2002 x11-base/xfree/files/4.2.0-r9/Sessions/Attic/Xsession,v
 Sep  8  2002 x11-base/xfree/files/4.2.0-r11/Attic/Xsession,v
 Sep  8  2002 x11-base/xfree/files/4.2.0-r11/Sessions/Attic/Xsession,v
 Sep  8  2002 x11-base/xfree/files/4.2.0-r9/Attic/Xsession,v
 May 31  2002 x11-base/xfree/files/4.2.0-r10/Attic/Xsession,v
 May 31  2002 x11-base/xfree/files/4.2.0-r10/Sessions/Attic/Xsession,v
 May 31  2002 x11-base/xfree/files/4.2.0-r8/Attic/Xsession,v
 May 31  2002 x11-base/xfree/files/4.2.0-r8/Sessions/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.2.0-r5/Sessions/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.2.0-r6/Sessions/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.2.0-r7/Sessions/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.1.0-r1/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.2.0-r5/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.2.0-r6/Attic/Xsession,v
 Apr  7  2002 x11-base/xfree/files/4.2.0-r7/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.2.0-r4/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.2.0-r4/Sessions/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.2.0-r3/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.2.0-r3/Sessions/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.2.0-r2/Sessions/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.2.0-r2/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.1.0-r5/Attic/Xsession,v
 Jan 28  2002 x11-base/xfree/files/4.1.0-r4/Attic/Xsession,v
 Jan 20  2002 x11-base/xfree/files/4.2.0-r1/Attic/Xsession,v
 Jan 20  2002 x11-base/xfree/files/4.2.0-r1/Sessions/Attic/Xsession,v
 Jan 20  2002 x11-base/xfree/files/4.2.0/Attic/Xsession,v
 Nov 11  2001 x11-base/xfree/files/Attic/Xsession,v
 Nov 11  2001 x11-base/xfree/files/4.1.0-r3/Attic/Xsession,v
 Nov 11  2001 x11-base/xfree/files/4.1.0-r2/Attic/Xsession,v

And Gnome,v:
 Dec 21  2006 gnome-base/gnome-core/files/Attic/Gnome,v
 Dec 15  2005 gnome-base/gnome-session/files/Gnome,v
 Jan 20  2002 x11-base/xfree/files/4.2.0-r1/Sessions/Attic/Gnome,v
Comment 10 Jim Ramsay (lack) (RETIRED) gentoo-dev 2007-12-17 18:33:53 UTC
What about when gdm or kdm starts the Fluxbox session - Should they run this too instead of 'startfluxbox'?  Or do they automatically do some of this magic already?
Comment 11 Jim Ramsay (lack) (RETIRED) gentoo-dev 2007-12-26 19:27:35 UTC
Alright, I have included this script in fluxbox-1.0.0-r1, thanks for submitting it!

I look forward to the day when this is all centralized.
Comment 12 Jim Ramsay (lack) (RETIRED) gentoo-dev 2009-06-25 12:50:22 UTC
Okay, maybe this will never, ever actually be centralized.