File tree Expand file tree Collapse file tree 2 files changed +26
-24
lines changed
Expand file tree Collapse file tree 2 files changed +26
-24
lines changed Original file line number Diff line number Diff line change 1010
1111namespace {
1212 std::string geometryDataDir () {
13- const char * path_lst_base = std::getenv ( " LST_BASE " ) ;
13+ std::string path_str, path ;
1414 const char * path_tracklooperdir = std::getenv (" TRACKLOOPERDIR" );
15- std::string path_str;
16- if (path_lst_base != nullptr ) {
17- path_str = path_lst_base;
18- } else if (path_tracklooperdir != nullptr ) {
15+ std::stringstream search_path;
16+ search_path << std::getenv (" CMSSW_SEARCH_PATH" );
17+
18+ while (std::getline (search_path, path, ' :' )) {
19+ if (std::filesystem::exists (path + " /RecoTracker/LSTCore/data" )) {
20+ path_str = path;
21+ break ;
22+ }
23+ }
24+
25+ if (path_str.empty ()) {
1926 path_str = path_tracklooperdir;
20- path_str += " /../ " ;
27+ path_str += " /.." ;
2128 } else {
22- std::stringstream search_path (std::getenv (" CMSSW_SEARCH_PATH" ));
23- std::string path;
24- while (std::getline (search_path, path, ' :' )) {
25- if (std::filesystem::exists (path + " /RecoTracker/LSTCore/data" )) {
26- path_str = path;
27- break ;
28- }
29- }
3029 path_str += " /RecoTracker/LSTCore" ;
3130 }
31+
3232 return path_str;
3333 }
3434
Original file line number Diff line number Diff line change @@ -7,18 +7,20 @@ DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
77source $DIR /code/rooutil/thisrooutil.sh
88
99ARCH=$( uname -m)
10- if [[ $( hostname) == * lnx4555* ]]; then
11- export SCRAM_ARCH=el9_amd64_gcc12
12- elif [[ $ARCH == " aarch64" || $ARCH == " arm64" ]]; then
13- export SCRAM_ARCH=el9_aarch64_gcc12
10+ if [ -z ${CMSSW_SEARCH_PATH+x} ]; then
11+ if [ -z ${FORCED_CMSSW_VERSION+x} ]; then
12+ export CMSSW_VERSION=CMSSW_14_2_0_pre4
13+ else
14+ export CMSSW_VERSION=$FORCED_CMSSW_VERSION
15+ fi
16+
17+ source /cvmfs/cms.cern.ch/cmsset_default.sh
18+ CMSSW_PATH=$( scram list -c CMSSW | grep -w $CMSSW_VERSION | awk ' {print $3}' )
19+ cd $CMSSW_PATH
20+ eval ` scramv1 runtime -sh`
1421else
15- export SCRAM_ARCH=el8_amd64_gcc12
22+ cd $CMSSW_BASE /src
1623fi
17- export CMSSW_VERSION=CMSSW_14_2_0_pre3
18-
19- source /cvmfs/cms.cern.ch/cmsset_default.sh
20- cd /cvmfs/cms.cern.ch/$SCRAM_ARCH /cms/cmssw/$CMSSW_VERSION /src
21- eval ` scramv1 runtime -sh`
2224
2325# Export paths to libraries we need
2426export BOOST_ROOT=$( scram tool info boost | grep BOOST_BASE | cut -d' =' -f2)
You can’t perform that action at this time.
0 commit comments