4 #Subrun follows $PROCESS+1
5 #After every 100 subruns, a new run is started
11 show_help # Display
a usage synopsis.
19 echo
"$0 ERROR: fcl requires a non-empty option argument."
24 # file=${1#*=} # Delete everything up to "=" and assign the remainder.
26 # --file=) # Handle the case of an empty --file=
27 # echo 'ERROR: "--file" requires a non-empty option argument.'
37 printf
"$0 WARN: Unknown option (ignored): %s\n" "$1" >&2
45 if [ -
z "$FCL" ]; then
46 echo
"$0 ERROR: fcl is mandatory"
50 #We need to extract what
the default run number is. Let
's get this from running lar and dumping the config
51 lar --debug-config lar_config_dump.txt -c $FCL
52 DEFAULTRUN=`grep -r "firstRun" lar_config_dump.txt`
53 #THis line is of the form firstRun: RUN
54 #We need to extract RUN
56 IFS=\: read -a DEFAULTRUNARRAY <<<"$DEFAULTRUN"
57 #Extract the run number
58 DEFAULTRUN=${DEFAULTRUNARRAY[1]}
59 #Get the subrun candidate number. We will need to do some modulo arithmetic to work out the actual run and subrun numbers
60 let "SUBRUNCANDIDATE= $PROCESS +1"
61 #Calculate how much to increment the run by
62 RUNINCREMENT=$((SUBRUNCANDIDATE/NSUBRUNSPERRUN))
63 #Calculate the run number
64 let "RUNNUMBER= $DEFAULTRUN + $RUNINCREMENT"
66 SUBRUNNUMBER=$((SUBRUNCANDIDATE%NSUBRUNSPERRUN))
67 echo "#Metadata injection by $0" >> $FCL
68 echo "source.firstRun: $RUNNUMBER" >> $FCL
69 echo "source.firstSubRun: $SUBRUNNUMBER" >> $FCL
process_name standard_reco_uboone fcl
process_name opflash particleana ie ie ie z
then echo Sam station was not specified(use option--sam_station)." exit 1 fi if [ x$SAM_GROUP
if &&[-z"$BASH_VERSION"] then echo Attempting to switch to bash bash shellSwitch exit fi &&["$1"= 'shellSwitch'] shift declare a IncludeDirectives for Dir in
then echo echo For and will not be changed by echo further linking echo echo B echo The symbol is in the uninitialized data multiple common symbols may appear with the echo same name If the symbol is defined the common echo symbols are treated as undefined references For more echo details on common see the discussion of warn common echo in *Note Linker options
then echo find_global_symbol finds mangled or demangled symbols in libraries echo within LD_LIBRARY_PATH match any symbol that echo contains name echo Default