echo "------------------------"
# WARNING : $installPrefixThird is taken from CreaTools-configure.sh
- # if user configured without installing third party library,
- # Last third party library is still in use! JPR
+ # If user configured without installing third party library,
+ # last third party library is still in use! JPR
if [ ! -f $installPrefixThird/share/creatools_third_party_library_config.sh ]
then
echo WARNING
echo
-# Install creatools as user (no longer as root) // JPR 2/5/2011
- #if [ ! -f /etc/bashrc ]
- #then
- # export ETC_BASHRC="/etc/bash.bashrc"
- #else
- # export ETC_BASHRC="/etc/bashrc"
- #fi
- export ETC_BASHRC=$HOME/.bashrc
+ if [ -f ETC_BASHRC=$HOME/.bashrc ]
+ then
+ export ETC_BASHRC=$HOME/.bashrc
+ else
+ if [ -f ETC_BASHRC=$HOME/.profile ]
+ then
+ export ETC_BASHRC=$HOME/.profile
+ fi
+ fi
echo "the curently used Third Party libraries are NOT in $installPrefixThird but in :"
grep "installPrefixThird=" $ETC_BASHRC
# ------------------
- loginUserName=""
- while [ "$loginUserName" == "" ]
- do
+ #loginUserName=""
+ loginUserName=$USER
+ #while [ "$loginUserName" == "" ]
+ #do
echo "Have a look at the following line to know 'Login User Name'/'Login Group Name'"
ls -l menu.sh
- echo "Login User Name (mandatory!)"
- read loginUserName
- echo "you said : [" $loginUserName "]"
- done
+ # echo "Login User Name (mandatory!)"
+ # read loginUserName
+ # echo "you said : [" $loginUserName "]"
+ #done
echo
echo
loginGroupName=""
while [ "$loginGroupName" == "" ]
do
- #echo "Have a look at the following line to know 'Login User Name'/'Login Group Name'"
- #echo "Login Group Name (mandatory!)"
+ echo "Have a look at the following line to know 'Login User Name'/'Login Group Name'"
echo "Login Group Name (mandatory!)"
read loginGroupName
echo "you said : [" $loginGroupName "]"
echo "---------------------------------------------------------------------"
fi
echo
+ echo "==>"
echo "==> You HAVE to leave current window to continue!"
+ echo "==>"
read a
- kill $PPID
+ kill -9 $PPID
;;
1.0)
1.1)
echo "========================== 1.1 "
- source scripts/Check-if-root.sh
- read a
- bash scripts/ThirdParty-install-VTK.sh
- read a
+ #source scripts/Check-if-root.sh
+ bash scripts/ThirdParty-install-VTK.sh
bash scripts/ThirdParty-install-Finalize.sh
read a
;;
1.2)
echo "========================== 1.2 "
- source scripts/Check-if-root.sh
+ #source scripts/Check-if-root.sh
bash scripts/ThirdParty-install-gdcm.sh
bash scripts/ThirdParty-install-Finalize.sh
;;
1.3)
echo "========================== 1.3 "
- source scripts/Check-if-root.sh
+ #source scripts/Check-if-root.sh
bash scripts/ThirdParty-install-ITK.sh
bash scripts/ThirdParty-install-Finalize.sh
read a
bash scripts/CreaTools-compile.sh
#2.3
bash scripts/CreaTools-install.sh
- echo "You HAVE to leave current window to continue!"
+ echo "==>"
+ echo "==> You HAVE to leave current window to continue!"
+ echo "==>"
read a
- kill $PPID
+ kill -9 $PPID
;;
2.1)
else
chown -R $loginUserName $generationdir/creatools_source
chgrp -R $loginGroupName $generationdir/creatools_source
- # Too much time consuming
- #chown -R $loginUserName $generationdir/creatools_source
- #chgrp -R $loginGroupName $generationdir/creatools_source
fi
;;
2.3)
-# if [ $UID != 0 ]
-# then
-# echo
-# echo "..ERROR.."
-# echo "==================================================="
-# echo "REMEMBER !"
-# echo ""
-# echo "YOU NEED TO RUN THIS ONE AS root"
-# echo "==================================================="
-# echo
-# echo
-# exit 0
-# fi
-
echo "========================= 4"
bash scripts/CreaTools-install.sh
echo "==================================="
# WARNING : $installPrefixThird is taken from CreaTools-configure.sh
- # if user configured without installing third party library,
- # Last third party library is still in use! JPR
+ # If user configured without installing third party library,
+ # last third party library is still in use! JPR
if [ ! -f $installPrefixThird/share/creatools_third_party_library_config.sh ]
echo WARNING
echo
echo "the curently used Third Party libraries are NOT in $installPrefixThird but in :"
- grep "installPrefixThird=" /etc/bashrc
+ grep "installPrefixThird=" $ETC_BASHRC
echo "VTK_DIR : " $VTK_DIR
echo "ITK_DIR : " $ITK_DIR
echo "GDCM_DIR : " $GDCM_DIR