Bug 219406 - pcb-doc: non-failsafe install-info usage
Summary: pcb-doc: non-failsafe install-info usage
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: pcb
Version: rawhide
Hardware: All
OS: Linux
medium
low
Target Milestone: ---
Assignee: Chitlesh GOORAH
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: FE7Target
TreeView+ depends on / blocked
 
Reported: 2006-12-12 22:31 UTC by Ville Skyttä
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2006-12-24 16:39:06 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Ville Skyttä 2006-12-12 22:31:23 UTC
pcb-doc's install-info invocations are not failsafe against excludedocs or
read-only-netsharedpath-/usr/share installations; appending "|| :" to the
invocations in %post and %preun would fix it.

Additionally, on a cosmetic note, install-info works on plain *.info too, no
need to explicitly specify the .gz extension if you like.

More info: http://fedoraproject.org/wiki/Packaging/ScriptletSnippets

Comment 1 Chitlesh GOORAH 2006-12-16 09:02:44 UTC
I'm opting for 

%post doc
/sbin/install-info %{_infodir}/%{name}.info %{_infodir}/dir || :

%preun doc
if [ $1 = 0 ]; then
    /sbin/install-info --delete %{_infodir}/%{name}.info %{_infodir}/dir || :
fi

would it do the job ?

Comment 2 Ville Skyttä 2006-12-16 15:59:19 UTC
That should do the trick.  On another cosmetic note, I'd use "[ $1 -eq 0 ]"
instead of "[ $1 = 0 ]" but both should work.

Comment 3 Chitlesh GOORAH 2006-12-24 16:39:06 UTC
Ok, Fixed!


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