Bug 478721 - escape uses gtk-update-icon-cache in its post(un)install scripts without handling the case where gtk2 isn't installed
escape uses gtk-update-icon-cache in its post(un)install scripts without hand...
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: escape (Show other bugs)
rawhide
All Linux
low Severity medium
: ---
: ---
Assigned To: Adam Goode
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-01-04 00:11 EST by Bruno Wolff III
Modified: 2009-01-10 23:02 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-01-04 01:13:53 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Bruno Wolff III 2009-01-04 00:11:49 EST
Description of problem:
The post install script for escape can fail when either gtk2 isn't installed or if it is being installed in the same transaction, but escape ends up being installed first.

Version-Release number of selected component (if applicable):
escape-200704130-9.fc10.i386.rpm

How reproducible:
Probably less than 100%, but shouldn't be too hard.

Steps to Reproduce:
1. Run livecd-creator on the games spin
2.
3.
  
Actual results:
  Installing: escape                       ################### [ 695/1260]
/var/tmp/rpm-tmp.t2tgkb: line 2: /usr/bin/gtk-update-icon-cache: No such file or directory

Expected results:
No error message.

Additional info:
The post(un)install scripts:
bash-3.2$ rpm -q --scripts escape
postinstall scriptlet (using /bin/sh):
touch --no-create /usr/share/icons/hicolor || :
/usr/bin/gtk-update-icon-cache --quiet /usr/share/icons/hicolor || :
postuninstall scriptlet (using /bin/sh):
touch --no-create /usr/share/icons/hicolor || :
/usr/bin/gtk-update-icon-cache --quiet /usr/share/icons/hicolor || :

I have been told the normal idiom for this kind of thing is:
touch --no-create /usr/share/icons/hicolor
if [ -x /usr/bin/gtk-update-icon-cache ]; then
  /usr/bin/gtk-update-icon-cache --quiet /usr/share/icons/hicolor || :
fi
Comment 1 Adam Goode 2009-01-04 01:13:53 EST
I've fixed it in rawhide, but I won't bother releasing updates for F9 and F10 since the message is annoying but harmless. If you disagree, please reopen this bug. :)
Comment 2 Bruno Wolff III 2009-01-04 01:32:16 EST
Rawhide is fine. I am trying to get livecd-creator to build a games spin for F11 and the script errors worried me a bit. But I do think you are right about the post install scripts failing with an error message isn't really different than failing silently in theory. In practice it might generate questions from people trying to use customized versions of the game spin kickstart file down the road. So getting it fixed is nice. Thanks.
Comment 3 Bruno Wolff III 2009-01-10 23:02:16 EST
I am just confirming that I am no longer seeing the error message in rawhide livecd-creator runs. Thanks.

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