root/release-kits/shared/uninstaller/Uninstall.sh @ 17794

Revision 17794, 0.7 KB (checked in by max, 11 years ago)

Fixed some bugs for the Uninstaller on the darwin platform and with Greenstone3.

Line 
1if [ -f "setup.bash" ]; then
2#This is Greenstone 2
3    . ./setup.bash > /dev/null
4    SEARCH4J_EXECUTABLE=$GSDLHOME/bin/$GSDLOS/search4j
5else
6#This is Greenstone 3
7    . ./gs2build/setup.bash > /dev/null
8    SEARCH4J_EXECUTABLE=./bin/search4j
9fi
10
11if [ $GSDLOS = linux ]; then
12    "$SEARCH4J_EXECUTABLE" -p ./packages/jre -l ./uninst.jar
13elif [ $GSDLOS = darwin ]; then
14    "$SEARCH4J_EXECUTABLE" -p /System/Library/Frameworks/JavaVM.framework/Home -l ./uninst.jar
15fi
16
17if [ -e "uninst.flag" ]; then
18
19    rm -rf packages/jre
20    rmdir packages
21   
22    rm -rf bin
23       
24    rm uninst.jar
25    rm uninst.flag
26    rm Uninstall.*
27   
28    CONTENTS=`ls`
29    if [ -z "$CONTENTS" ]; then
30        GSDEL=`pwd`
31        cd ..
32        rmdir $GSDEL
33    fi
34fi
Note: See TracBrowser for help on using the browser.