Red Hat Bugzilla – Bug 481352
xdg-desktop-menu installs in /usr/local/share/applications
Last modified: 2009-02-19 05:22:10 EST
Description of problem:
I found unowned aqsis desktop files in /usr/local/share/applications. They were created the same day I installed aqsis. I tested by doing an rpm -e of the aqsis packages; the files were removed. Since the aqsis scripts use xdg-desktop-menu to install and remove the desktop files, it appears that xdg-desktop-menu is to blame.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Install aqsis
2. Unowned desktop files appear in /usr/local/share/applications
3. Uninstall aqsis
4. The desktop files disappear (but defaults.list and mimeinfo.cache remain)
Desktop files are installed to and uninstalled from /usr/local/share/applications.
/usr/local shouldn't be touched
aqsis shouldn't be calling xdg-desktop-menu in %post (that's something for *build* time, not *install* time, which it already does via desktop-file-install) and is a packaging bug, reassigning
In short, just remove all the
calls in %post (etc...) , and all should well.
Looking closer in cvs, I'm not sure you really want to be doing all those 'uninstall' operations in %pre either. rpm is funky, one upgrade, the scriplets from the old pkgs are run *after* those from the upgraded one. So, in the least, you'll want to wrap those in something like
if [ $1 -eq 0 ]; then
to ensure they're only run on erasure, and not pkg upgrades.
to be clear, that last comment was intended for the aqsis maintainer(s)
OK, double-checked, instead of
I'm pretty sure you want to replace the
install icons during %build, and add to scriptlets:
xdg-icon-resource forceupdate --theme hicolor
It seems that's shouldn't have trusted upstream when they started to make rpm.
Their needs doesn't really fit ours as they cannot expect some tools to be available while registering the desktop files , icons and the mimetype.
Shoudn't the xdg tools done for that purpose after all ? (to be distro agnostic?)
On the other hand, if it install unowned files in /usr/local, that doesn't worth to use the xdg tools, I will revert back to the well documented %post install scriplet to register the icons and desktop files with the mime-types
(I'm just not sure about xdg-icon-resource equivalent).
aqsis-1.4.2-2.fc10 has been pushed to the Fedora 10 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
su -c 'yum --enablerepo=updates-testing update aqsis'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-1199
This bug was fix with the above update