X.Org session start (via xinit) loses LD_LIBRARY_PATH
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
xorg (Ubuntu) |
Triaged
|
Wishlist
|
Unassigned |
Bug Description
Binary package hint: x11-common
Some background:
I am working on the Mesa Radeon driver. When testing out Git-based X.Org and Mesa, I keep self-compiled things in their own prefix (contained in my home directory) because I want to keep Ubuntu-supplied packages clean. To test things, I shutdown GDM and start X manually. However, I want to keep as much of the default Ubuntu *client* aspects the default, so I start via xinit (passing a sudo-wrapper for the X server and setting environment variables as appropriate).
In particular, I need to set LD_LIBRARY_PATH, as otherwise clients will not find the right libGL.so.
Expected behaviour would be that the environment with which I call xinit is the environment that clients in the session will see.
However, this is not the case, because ssh-agent (which is setuid) is indirectly a parent of all clients.
I worked around this by adding a small script to /etc/X11/
STARTUP=
before the script that adds the ssh-agent (I guess it would make more sense to put this into the script that adds the ssh-agent to $STARTUP, but I didn't want to change any files installed by packages).
I realize that I'm as fringe a usecase as you can be, but since this is *really* surprising behaviour, took me about two hours to figure out (just digging to what happens at X session startup takes a long time if you've never done it), and is quite simple to fix,so I'd appreciate it if you considered fixing this.
ProblemType: Bug
Architecture: i386
DistroRelease: Ubuntu 9.04
Package: xorg 1:7.4~5ubuntu18
ProcEnviron:
LANGUAGE=
LANG=en_US.UTF-8
SHELL=/bin/bash
ProcVersion: Linux version 2.6.28-11-generic (buildd@palmer) (gcc version 4.3.3 (Ubuntu 4.3.3-5ubuntu4) ) #42-Ubuntu SMP Fri Apr 17 01:57:59 UTC 2009
SourcePackage: xorg
Uname: Linux 2.6.28-11-generic i686
[lspci]
00:00.0 Host bridge [0600]: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub [8086:27a0] (rev 03)
Subsystem: Lenovo Device [17aa:2017]
00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller [8086:27a2] (rev 03)
Subsystem: Lenovo Device [17aa:201a]
affects: | xorg (Ubuntu) → xserver-xorg-video-intel (Ubuntu) |
affects: | xserver-xorg-video-intel (Ubuntu) → xorg (Ubuntu) |
Changed in xorg (Ubuntu): | |
importance: | Undecided → Wishlist |
status: | New → Triaged |
description: | updated |
Another reasonable workaround for your case would be to not run ssh-agent, for instance by disabling it in /etc/X11/ Xsession. options
For a proper fix, please report a bug in Debian. I don't think Ubuntu wants to divert from Debian in order to accommodate this unusual usage pattern.