FS#3663 - new Xorg prevents things from seeing .desktop files in /usr/share/applications

Attached to Project: Arch Linux
Opened by name withheld (Gullible Jones) - Monday, 26 December 2005, 01:32 GMT
Task Type Bug Report
Category Packages: Testing
Status Closed
Assigned To Jan de Groot (JGC)
Architecture not specified
Severity High
Priority Normal
Reported Version 0.7 Wombat
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

If you use Xorg 7.0 and a desktop environment or a menu generator that uses .desktop files, packages that put their .desktop files in /usr/share/applications - Archlinux-menus and Cube, for example - will not generate menu entries.

The problem (recognized by Lunke) is that the new version of Xorg changes XDG_DATA_DIRS, and fails to include /usr/share. THERE IS A SIMPLE SOLUTION TO THIS PROBLEM, but it should be implemented by default.

To solve this vexxing problem, add these two lines to /etc/profile:

XDG_DATA_DIRS=$XDG_DATA_DIRS:/usr/share
export XDG_DATA_DIRS

After a relogin (or 'source /etc/profile'), the menu entries will show up.

I'm not sure about the status of .desktop files in ~/.local/share/applications, nor why the Xorg people changed the defaults for XDG_DATA_DIRS. At any rate, though, I suggest that all the possible directories for .desktop files be added to /etc/profile in the fashion shown above, in case something like this happens again in the future.
This task depends upon

Closed by  Jan de Groot (JGC)
Saturday, 31 December 2005, 12:00 GMT
Reason for closing:  Fixed
Additional comments about closing:  I stuffed the file in xproto, the package nearly every Xorg package depends on.
Comment by Jan de Groot (JGC) - Monday, 26 December 2005, 13:05 GMT
We used to include those dirs with a nice /etc/profile.d/xorg.sh scriptlet. Since Xorg is tons of packages now, I think it's best to put the lines in /etc/profile nowadays or put the xorg.sh file in /etc/profile.d again with the normal package that is responsible for /etc/profile too.
Comment by name withheld (Gullible Jones) - Monday, 26 December 2005, 17:11 GMT
Would be nice if it were done by default though. Why can't the xorg-server package include it?
Comment by Jan de Groot (JGC) - Monday, 26 December 2005, 18:00 GMT
When running remote X, you don't need xorg-server on the system with all the applications on it, but you would like to have the xorg.sh file or at least the settings in them. Since XDG_DATA_DIRS and those things in this file are so trivial, we should have it in a base package. Currently, we have 3 choices:

- put it in libxdmcp, libxau or xproto
- put it in bash, since that one provides /etc/profile
- add it to another basic package like "filesystem"
Comment by name withheld (Gullible Jones) - Monday, 26 December 2005, 21:24 GMT
Libxdmcp looks like a good bet, I would think, judging from the description. It might be better to put it in filesystem if Arch ever supports fish as well as bash, but my gut instinct says that we should keep X and CLI stuff apart.

Loading...