GNOME Bugzilla – Bug 604206
GCONF_DEFAULT_SOURCE_PATH does not work as expected
Last modified: 2010-04-24 09:07:58 UTC
GDM has a unique requirement. Since multiple login GUI's can be displayed at the same time (e.g. one on the console and one via XDMCP, or in a terminal server setting), each instance of the gdm-simple-greeter really should have its own GConf settings. When the GDM login GUI is showing, gnome-session will use the GDM accessibility autostart files to launch AT programs based on a GConf key. For example, using GDM 2.28, the /usr/share/gdm/autostart/LoginWindow/orca-screen-reader.desktop file will cause orca to launch when the following GConf key is true: /desktop/gnome/applications/at/screen_reader_enabled So, if a user launches an AT program on one display by clicking on the checkbox in the GDM a11y dialog, then it will launch on all displays. If the user, unchecks the checkbox, then it is removed from all displays. Note GDM bug #594818. https://bugzilla.gnome.org/show_bug.cgi?id=594818 I wrote the proposed patch in this bug that fixes for this behavior. The latest patch makes use of $GCONF_DEFAULT_SOURCE_PATH so that each ConsoleKit Seat saves its own separate GConf settings. Thus, when you start an AT program on one display, it only starts on that display. GDM does this by setting $GCONF_DEFAULT_SOURCE_PATH to a file and setting the $GDM_SEAT_ID environment variable to the name of the seat before starting any GUI programs. The file specified by $GCONF_DEFAULT_SOURCE_PATH has the following line: xml:readwrite:$(HOME)/$(ENV_GDM_SEAT_ID)/.gconf This, for example, will save the GConf data for Seat1 in the directory /var/lib/gdm/Seat1/.gconf. Other Seats will save their data in separate directories. All this works. However, this only seems to work if the reference to $(ENV_SEAT_ID) is in the exact file specified by $GCONF_DEFAULT_SOURCE_PATH. If I move the line referencing $(ENV_SEAT_ID) into a file that is included by the file specified by $GCONF_DEFAULT_SOURCE_PATH, then the behavior changes as follows: 1) It seems that the .gconf data is still properly being saved to the right directory (e.g /var/lib/gdm/Seat1/.gconf) 2) However, the GConf notifications still get sent to clients on all Seats, so that a11y programs get launched on all displays. I would think that this should work regardless of whether $GDM_SEAT_ID is specified in the top-level path file or an included file. Any idea why I am seeing this sort of odd behavior? Looking at the GConf code, it does look like GConf parses included files much the same way as the top-level file. So, I am confused why this does not work. The proposed patch for bug #594818 is a bit hacky (see comment #3), and it would be possible to make this fix much more clean if the $(ENV_SEAT_ID) could be moved to an included file. I would appreciate any feedback or thoughts about what the problem might be or how to fix the GDM issue in a cleaner way. Thanks.
Perhaps if it were fixed so that $GDM_SEAT_ID could be specified and work in included files this would allow me to just set the readwrite directory in the ~gdm/.gconf.path and avoid needing to set $GCONF_DEFAULT_SOURCE_PATH at all), which would be a less intrusive way to fix that GDM problem.
Never mind, after further research I discovered that there is no bug. You can refer to comment #5 of bug #594818 for more information.