# modification history
#
# $Log$
+# Revision 1.7 2001/05/21 17:22:52 buncic
+# Fixed problem with missing AliConfig while reading galice.root
+#
+# Revision 1.6 2001/05/16 14:57:30 alibrary
+# New files for folders and Stack
+#
#
# Revision 1.5 2001/02/23 17:33:40 buncic
# Added alifs wrapper for CASTOR and alirun modified accordingly.
# - Reco ................ reconstruction
#
# -d <TPC+ITS+..> | -d all | -all
-# Selects detector for which <command> will be run. If none of these options was specified, an internal loop in AliRoot over all active detectors is assumed. Otherwise, for each detector, input file(s) are re-opened in update mode, command (or macro) is executed and the file is closed. Option -all is equivalent to MUON+RICH+TOF+ITS+TPC+PHOS+PMD+CASTOR+TRD. Detectors are processed in order as they appear on the command line.
+# Selects detector for which <command> will be run. If none of these options was specified, an internal loop in AliRoot over all active detectors is assumed. Otherwise, for each detector, input file(s) are re-opened in update mode, command (or macro) is executed and the file is closed. Option -all is equivalent to MUON+HMPID+TOF+ITS+TPC+PHOS+PMD+CASTOR+TRD. Detectors are processed in order as they appear on the command line.
#
# -f <file>
# Name of the top level Root file where Root trees will be stored (branches may reside in the same file or be diverted to separate files (see -split option). By default, file is named galice.root.
#
# alirun -o /tmp/event.2 -f test.root -split -p 100 -c Hits
#
-# Use output from first step and create TOF and RICH digits. Output is in the same direcory and in file test.root
+# Use output from first step and create TOF and HMPID digits. Output is in the same direcory and in file test.root
#
-# alirun -d TOF+RICH -o /tmp/event.1 -c Digits
+# alirun -d TOF+HMPID -o /tmp/event.1 -c Digits
#
# Use output from second step and create digits for all detectors. Output is in the same direcory and branches are diverted to separate files:
#
exec $ALIRUN_SHELL -norc -noprofile $0 $*
fi
+
###########################################################################
AliRun()
###########################################################################
exit
}
+###########################################################################
+AliSetRoot()
+###########################################################################
+{
+ ALICE_ROOT=$1; export ALICE_ROOT
+ ALICE=`dirname $ALICE_ROOT`; export ALICE
+ ALICE_LEVEL=`basename $ALICE_ROOT`; export ALICE_LEVEL
+ ALICE_TARGET=`uname`; export ALICE_TARGET
+ ROOTSYS=$2; export ROOTSYS
+
+ LD_LIBRARY_PATH=$ROOTSYS/lib
+
+ if [ -f $ALICE/bin/changeRoot.sh ]
+ then
+ . $ALICE/bin/changeRoot.sh \
+ $ALICE $ALICE_LEVEL $ALICE_TARGET $ROOTSYS
+ fi
+
+ if [ ! -x $ALICE_BIN/aliroot -o ! -x $ROOTSYS/bin/root ]
+ then
+ printf "Invalid Alice library directory: %s\n" $1
+ exit 1
+ fi
+
+ LD_LIBRARY_PATH=${ROOTSYS}/lib:${ALICE_LIB}; export LD_LIBRARY_PATH
+ PATH=${ALICE_BIN}:${ROOTSYS}/bin:${PATH}; export PATH
+
+ printf "ALICE environment reset to %s\n" $ALICE_ROOT
+ which root
+ which aliroot
+}
+
###########################################################################
Mktemp()
###########################################################################
###########################################################################
-ALL="MUON RICH TOF ITS TPC PHOS PMD CASTOR ZDC TRD";
+ALL="MUON HMPID TOF ITS TPC PHOS PMD CASTOR ZDC TRD";
DETECTORS="";
FILE="galice.root";
CMDLIST=""
FORK="FALSE"
FORK_LSF="FALSE"
+BATCH="FALSE"
ECHO=""
NEVENTS=1
USE_CACHE="file->UseCache()"
shift 1
set -vx
;;
+ -setroot)
+ shift 1
+ AliSetRoot $1 $2
+ shift 1
+ ;;
+ -batch)
+ shift 1
+ BATCH="TRUE"
+ ;;
-echo)
shift 1
ECHO="echo "
$MKDIR -p $CONFIG_OUTDIR
fi
-mkdir -p $ALIRUN_TMPDIR
-
CONFIG_FILE=$CONFIG_FILE_PREFIX$CONFIG_OUTDIR/$FILE; export CONFIG_FILE
+mkdir -p $ALIRUN_TMPDIR
+
trap Cleanup 2
(