Bug 224588

Summary: Error in post uninstall script
Product: [Fedora] Fedora Reporter: Phil Knirsch <pknirsch>
Component: eclipseAssignee: Ben Konrath <ben>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: rvokal
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 3.2.1-33.fc7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-01-30 03:40:30 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Phil Knirsch 2007-01-26 15:39:46 UTC
During an automated install/deinstall check the following error has happened:

ERROR: Output running post uninstall script for package
eclipse-sdk-1:3.2.1-30.fc7.i386
ls: cannot access /usr/lib/eclipse/features: No such file or directory

Checking whether the directory exists before doing an ls on it should fix the
problem.

postuninstall scriptlet (using /bin/sh):
if [ -x /usr/bin/rebuild-gcj-db ]
then
  /usr/bin/rebuild-gcj-db
fi
# Only set the product back to platform.ide if the sdk is actually removed for
# this arch.  This SDKDIR check is to deal with the ordering of new %post
# before old %postun
if [ -d /usr/lib/eclipse/features]; then
  SDKDIR=$(ls /usr/lib/eclipse/features | grep "org\.eclipse\.sdk_")
else
  SDKDIR=""
fi
if [ -z "$SDKDIR" -a -f /usr/lib/eclipse/configuration/config.ini ]; then
  sed --in-place
"s/[#]*eclipse.product=.*/eclipse.product=org.eclipse.platform.ide/" \
    /usr/lib/eclipse/configuration/config.ini
fi

Comment 1 Ben Konrath 2007-01-26 18:24:46 UTC
Looks good. Feel free to commit.

Comment 2 Ben Konrath 2007-01-30 03:40:30 UTC
This is fixed in rawhide (3.2.1-33.fc7). Thanks.

Comment 3 Ben Konrath 2007-02-21 21:54:50 UTC
A fix for this will also be in the upcoming 3.2.2-1.fc6 update. Thanks.