[Solved] Gnome 3 is not using /usr/local/share/applications

This forum is dedicated to basic help and support :

Ask here your questions about basic installation and usage of Mageia. For example you may post here all your questions about getting Mageia isos and installing it, configuring your printer, using your word processor etc.

Try to ask your questions in the right sub-forum with as much details as you can gather. the more precise the question will be, the more likely you are to get a useful answer

[Solved] Gnome 3 is not using /usr/local/share/applications

Postby keitolainen » Jul 5th, '14, 23:02

Hello,

I recently switched to Mageia 4 (using Gnome 3) from OpenSuse and I'm having an issue with Gnome not finding desktop files I have put in /usr/local/share/applications. They don't show up in the application menu at all, either using a search or looking under all applications. These are mostly programs that I want all users to have access to, so I don't want to use $HOME/.local/share/applications. Is there a simple setting somewhere that will let these files be read? Desktop files in /usr/share/applications work properly.

Thanks
Last edited by keitolainen on Jul 6th, '14, 19:02, edited 1 time in total.
keitolainen
 
Posts: 3
Joined: Jul 5th, '14, 22:51

Re: Gnome 3 is not using /usr/local/share/applications

Postby doktor5000 » Jul 6th, '14, 17:49

Did you validate the .desktop files with
Code: Select all
desktop-file-validate
? And please provide the content of one of the files that isn't shown in menu.

Also, as normal user, please post the output from
Code: Select all
set | grep XDG


You may also want to look at https://developer.gnome.org/menu-spec/#paths and/or https://developer.gnome.org/integration ... es.html.en
But why not simply copy the file to /usr/share/applications?
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18067
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Gnome 3 is not using /usr/local/share/applications

Postby keitolainen » Jul 6th, '14, 18:57

Thanks for the response. Those programs are all showing up in the menu now, after a few reboots. The only thing I can think of that changed is that I added "/usr/local/games" to PATH in /etc/profile. I'm guessing that since the exec commands in the desktop files weren't in the path, they didn't show up in the menu. Does that make sense?

To answer your questions though, here is one of the files that wasn't showing up:
Code: Select all
[Desktop Entry]
Categories=Game;
Encoding=UTF-8
Name=Bastion
GenericName=Bastion
Comment=Indie Action Role-Playing Game
Exec=bastion
Icon=/opt/bastion/Bastion.png
Type=Application
desktop-file-validate throws a warning about the Encoding key being deprecated, but otherwise it seems fine.

Here is the other output you asked for:
Code: Select all
$ set | grep XDG
XDG_CONFIG_DIRS=/etc/xdg:/etc/xdg/gnome
XDG_MENU_PREFIX=gnome-
XDG_RUNTIME_DIR=/run/user/500
XDG_SEAT=seat0
XDG_SESSION_ID=1
XDG_VTNR=1

I hope that helps anyone having a similar problem.
keitolainen
 
Posts: 3
Joined: Jul 5th, '14, 22:51

Re: Gnome 3 is not using /usr/local/share/applications

Postby doktor5000 » Jul 6th, '14, 19:14

keitolainen wrote:The only thing I can think of that changed is that I added "/usr/local/games" to PATH in /etc/profile. I'm guessing that since the exec commands in the desktop files weren't in the path, they didn't show up in the menu. Does that make sense?

No that's unrelated, Probably the reboot forced a rebuild of the menu, usually that happens during runtime.
keitolainen wrote:Here is the other output you asked for:
Code: Select all
$ set | grep XDG
XDG_CONFIG_DIRS=/etc/xdg:/etc/xdg/gnome
XDG_MENU_PREFIX=gnome-
XDG_RUNTIME_DIR=/run/user/500
XDG_SEAT=seat0
XDG_SESSION_ID=1
XDG_VTNR=1

I hope that helps anyone having a similar problem.


Have a look at the links in previous post, IMHO you're missing $XDG_DATA_DIRS
Code: Select all
[doktor5000@Mageia4 ~]$ set | grep XDG
XDG_CONFIG_DIRS=/etc/xdg:/etc/xdg/kde4
XDG_CURRENT_DESKTOP=KDE
XDG_DATA_DIRS=/usr/share:/usr/share:/usr/local/share
XDG_MENU_PREFIX=kde-
XDG_RUNTIME_DIR=/run/user/500
XDG_SEAT=seat0
XDG_SESSION_ID=1
XDG_VTNR=1


And thumbs up for Bastion ;) Hope they'll release the linux build for Transistor soon ...
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18067
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: [Solved] Gnome 3 is not using /usr/local/share/applicati

Postby keitolainen » Jul 6th, '14, 21:31

Will do, thanks again.
keitolainen
 
Posts: 3
Joined: Jul 5th, '14, 22:51


Return to Basic support

Who is online

Users browsing this forum: No registered users and 1 guest

cron