]> Creatis software - creaToolsTools.git/blob - Install/scripts/uninstall.sh
ba4c01755a5dc90e99ac9a116839cb811388cb48
[creaToolsTools.git] / Install / scripts / uninstall.sh
1 #!/bin/sh
2
3
4 if [ $UID = 0 ] 
5 then
6   # Set all local variables
7   source $PWD/configure.sh
8   
9   cd $installPrefix
10   
11   cd bin
12   # Maybe too much brute! (What if anything else starts with 'bb' or 'crea'?)
13   rm -f bb*
14   rm -f crea*
15   
16   cd ../include
17   # Maybe too much brute! (What if anything else starts with 'bb' or 'crea'?)
18   rm -rf bb*
19   rm -rf crea*  
20   
21   cd ../lib
22   # this one is riskless
23   rm -rf creatools
24   
25   cd ../share
26   # this one is riskless
27   rm -rf bbtk creaImageIO creaNewProject creaContours creaMaracasVisu  
28   rm -f creatools_base_library_config.sh
29
30   # revert /etc/bashrc to previous value  
31   # - remove line 'sh $installPrefix/creatools_install/share/creatools_base_party_libraries_config.sh'
32   sed -i -e '/.*creatools_base_library_config.*/ d' /etc/bashrc 
33
34 else
35   echo
36   echo "..ERROR.."
37   echo "==================================================="
38   echo "REMEMBER !"
39   echo ""
40   echo "YOU NEED TO RUN THIS ONE AS root"
41   echo "==================================================="
42   echo
43   echo
44 fi 
45