--- childsplay-0.90.2/childsplay_plugins_lfc-0.90/install.sh 2007-08-25 09:53:57.000000000 +0200 +++ childsplay-0.90.2/childsplay_plugins_lfc-0.90/install.sh-gil 2008-09-27 05:36:28.000000000 +0200 @@ -8,32 +8,33 @@ # However, you can change the "prefix" to "/usr" and childsplay will still # work. Set it to anything else and your on your own. -PREFIX=/usr/local +PREFIX=/usr ################################################################# # DON'T EDIT BEHIND THIS POINT ################################################################# -if [ $1 ] && [ -e $1 ] -then PREFIX=$1 -fi +DESTDIR= + +[ "$1" ] && DESTDIR="$1" -LOCALEDIR=$PREFIX/share/locale -ASSETMLDIR=/usr/share/assetml +LOCALEDIR=$DESTDIR$PREFIX/share/locale +MTDIR=$DESTDIR$PREFIX/bin +ASSETMLDIR=$DESTDIR$PREFIX/share/assetml PYTHON=`which python` -SCOREDIR=/var/games -DOCDIR=$PREFIX/share/doc/childsplay -MANDIR=$PREFIX/man/man6 -CPDIR=$PREFIX/lib/games/childsplay -SHAREDIR=$PREFIX/share/childsplay -BINDIR=$PREFIX/games +SCOREDIR=$DESTDIR/var/games +DOCDIR=$DESTDIR$PREFIX/share/doc/childsplay +MANDIR=$DESTDIR$PREFIX/man/man6 +CPDIR=$DESTDIR$PREFIX/lib/childsplay +SHAREDIR=$DESTDIR$PREFIX/share/childsplay +BINDIR=$DESTDIR$PREFIX/bin SHARELIBDATADIR=$SHAREDIR/lib SHAREDATADIR=$SHAREDIR/Data ################################################## # Package text to be displayed as last step # 0 = no readmes to display, 1 = there are readmes -README=1 +README=0 # if README=1 then READMES=names of readmes in CWD # like this READMES="README README2 README3" READMES="README" @@ -42,52 +43,11 @@ CWD=`pwd` -USERID=`id | sed -e 's/).*//; s/^.*(//;'` -if [ "$USERID" != "root" ]; then - echo " You must be root to install the plugins" - echo " exit" - exit 1 -fi - echo -e "\n>>>>>>>>>>> Install childsplay plugins >>>>>>>>>>>>>>>>>>>>" echo -e "\n This release depends on childsplay version >= $DEPEN" -echo -n " Checking, version = " -#CP=`which childsplay` -CP=$BINDIR/childsplay -VERSION=$($CP --version) -echo $VERSION - -if [ `expr $VERSION \< $DEPEN` -eq 1 ] -then - echo " Childsplay version incorrect, please upgrade to at least"; - echo " version $DEPEN"; - echo "exit"; - exit 1 -fi - -if [ ! -f $CP ] -then echo "############# Can\`t find childsplay ###########" && \ - echo "Be sure to install childsplay first" && \ - exit 1 -fi set -e -echo -e "\n The path to install the plugins in is $CPDIR." -echo " If you have installed childsplay in a other place, you can" -echo " give the full path to childsplay, otherwise just hit enter" -echo " Hit enter to install in $CPDIR, or give the full path" -read path -if [ $path ];then - if [ -e $path/install.py ];then - CPDIR=path - else - echo "*********** WARNING *************" - echo " $path does not exists or is not the childsplay directory" - echo " exit" - exit 1 - fi -fi echo " Installing in $CPDIR" echo "Compiling modules to bytecode..." @@ -138,5 +98,4 @@ echo " in your home directory." echo "***********************************************************************" echo " Enjoy childsplay :-)" -echo "" - +echo "" \ No newline at end of file