#!/bin/sh # Set SAGE_ROOT to the location of the sage install. SAGE_ROOT="....." CUR="`pwd`" # save the current directory, so can change back after startup if [ "$SAGE_ROOT" = "....." ]; then SAGE_ROOT=`echo "$0" | sed -e 's/....$//g'` if [ ! -f "$SAGE_ROOT/local/bin/sage-sage" ]; then echo "**************************************************************************" echo "You must compile SAGE first using 'make' in the SAGE root directory." >&2 echo "(If you have already compiled SAGE, you must set the SAGE_ROOT variable in " echo "the file '$0')". echo "**************************************************************************" exit 1 fi fi # Make root absolute: cd "$SAGE_ROOT" SAGE_ROOT=`pwd` export SAGE_ROOT export CUR "$SAGE_ROOT/local/bin/sage-sage" $* # This should kill all children of this process too. # Uncomment this if you have trouble with orphans. # Note that you'll get an annoying "Killed" message # whenver SAGE exists. # kill -9 -$$