Bug 501355 - postinstall scriptlet of chemical-mime-data fails
Summary: postinstall scriptlet of chemical-mime-data fails
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: chemical-mime-data
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Julian Sikorski
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-05-18 17:31 UTC by Bruce Jerrick
Modified: 2009-05-18 17:56 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-05-18 17:56:03 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Bruce Jerrick 2009-05-18 17:31:49 UTC
Description of problem:
The postinstall scriptlet of chemical-mime-data fails during installation
of Fedora 11 (rawhide).

Version-Release number of selected component (if applicable):
chemical-mime-data-0.1.94-5.fc11

How reproducible:
Depends on the exact package mix.  Always happens if chemical-mime-data
gets installed before gtk2 .

Steps to Reproduce:
1. Install Fedora 11 OS, with chemical-mime-data included.
2. grep -A 2 "Installing chemical-mime-data" /root/install.log
  
Actual results:
Installing chemical-mime-data-0.1.94-5.fc11.noarch
/var/tmp/rpm-tmp.b2t145: line 3: /usr/bin/gtk-update-icon-cache: \
    No such file or directory

Expected results:
No error message in /root/install.log .

Additional info:
The problem is evident from examination of the postinstall scriptlet
of chemical-mime-data.spec .  The postinstall scriptlet invokes
/usr/bin/gtk-update-icon-cache, but there is no Requires(post) entry
that will pull it in, except by chance.

The fix is simple:  Add this to chemical-mime-data.spec:

    Requires(post): /usr/bin/gtk-update-icon-cache
    Requires(postun): /usr/bin/gtk-update-icon-cache

(the latter for good measure, to cover the postuninstall scriptlet).

Comment 1 Julian Sikorski 2009-05-18 17:56:03 UTC
This is intentional. Have a look at https://fedoraproject.org/wiki/Packaging/ScriptletSnippets#Icon_Cache. It says:
“Note that no dependencies should be added for this. If gtk-update-icon-cache is not available, there's nothing that would be needing the cache update, ditto if "touch" is not available, there's nothing that would benefit from icon cache updates installed yet either. Not adding the dependency on gtk-update-icon-cache (ie. gtk2 >= 2.6.0) or "touch" makes it easier to use the package (or the same specfile) on systems where it's not available nor needed, such as older distro versions or (very) trimmed down installations, and generally results in less entries in specfiles, rpmdb, and repo metadatas.”


Note You need to log in before you can comment on or make changes to this bug.