diff --git a/install_circompara b/install_circompara index c6e848b..9989419 100755 --- a/install_circompara +++ b/install_circompara @@ -3,26 +3,24 @@ export CIRCOMPARA_HOME=$(dirname $(readlink -f $0)) mkdir $CIRCOMPARA_HOME/tools -## check whether Scons is installed and install it if not +mkdir -p $CIRCOMPARA_HOME/bin + +export PATH=$CIRCOMPARA_HOME/bin/:$PATH +## export environment variable for local R repository +export R_LIBS=$CIRCOMPARA_HOME/tools/R_libs + ## install Scons -command -v scons >/dev/null 2>&1 ||\ -{ echo >&2 "I require Scons but it's not installed. Installing Scons..."; cd $CIRCOMPARA_HOME/tools; -wget -N -c http://prdownloads.sourceforge.net/scons/scons-local-2.5.1.tar.gz; +wget -N -c http://prdownloads.sourceforge.net/scons/scons-local-3.1.2.tar.gz; mkdir -p scons -tar -xf scons-local-2.5.1.tar.gz -C scons ; +tar -xf scons-local-3.1.2.tar.gz -C scons ; ln -s $CIRCOMPARA_HOME/tools/scons/scons.py $CIRCOMPARA_HOME/bin/scons; -cd - ;} +cd - cd $CIRCOMPARA_HOME/bin ln -s ../src/*.py . ln -s ../src/*.R . cd - -export PATH=$CIRCOMPARA_HOME/bin/:$PATH - -## export environment variable for local R repository -export R_LIBS="$CIRCOMPARA_HOME/tools/R_libs" - ## install other tools -scons -i -f $CIRCOMPARA_HOME/src/ccp_install_tools.scons $1 +$CIRCOMPARA_HOME/bin/scons -i -f $CIRCOMPARA_HOME/src/ccp_install_tools.scons $1