.so cleanup: more less-obvious cleanup
authordberzano <dario.berzano@cern.ch>
Fri, 12 Dec 2014 13:45:10 +0000 (14:45 +0100)
committeragrigora <alina.grigoras@cern.ch>
Mon, 15 Dec 2014 12:52:12 +0000 (13:52 +0100)
22 files changed:
EVE/macros/alieve_loadlibs.C
FMD/scripts/RunAnaKine.C
HMPID/Hconfig.C
ITS/macrosSDD/ITSQArecoparam.C
PWG/muon/RunSingleMuonAnalysisFromAOD.C
PWGCF/FLOW/Documentation/examples/manual/ttree/macros/readTTree.C
PWGCF/FLOW/macros/fqd.C
PWGGA/PHOSTasks/PHOS_PbPb/macros/single-task/setupPi0Flow.C
PWGHF/correlationHF/macros/run-single-task.C
PWGHF/correlationHF/macros/setupDxHFE.C
PWGPP/MUON/dep/RunMuonResolution.C
PWGPP/MUON/lite/PlotMuonQA.C
PWGPP/MUON/lite/RunMuonQA.C
PWGPP/MUON/lite/mergeGridFiles.C
PWGPP/MUON/lite/terminateQA.C
PWGPP/TRD/macros/makeCalibResults.C
PWGPP/TRD/macros/makeResults.C
PWGPP/macros/taskComp.C
PWGPP/pid/doeffAllSpecies.C
TPC/macros/RunAliTPCCalibKrTask.C
macros/loadlibs.C
macros/loadlibssim.C

index 97f7acd..a6f4197 100644 (file)
@@ -47,7 +47,7 @@ void alieve_loadlibs ()
   gSystem->Load("libAliPythia6");
 
   gSystem->Load("libhijing");
-  gSystem->Load("libTHijing");// AliGenHijingEventHeader needed by libZDCsim.so
+  gSystem->Load("libTHijing");// AliGenHijingEventHeader needed by libZDCsim
 
   gSystem->Load("libSTRUCT");
   gSystem->Load("libPHOSbase");
index 9f6ea42..50c4ac5 100644 (file)
@@ -14,8 +14,8 @@ RunAnaKine(Bool_t primary_only=false, Bool_t segmented=true)
   //  true                | ok     | ok
   //  
   // gROOT->LoadMacro("Compile.C");
-  // gSystem->Unload("AliFMDAnaFlowKine_C.so");
-  // gSystem->Unload("AliFMDAnaFlowRing_h.so");
+  // gSystem->Unload("AliFMDAnaFlowKine_C");
+  // gSystem->Unload("AliFMDAnaFlowRing_h");
   if (!Compile("AliFMDAnaFlowRing.h")) return;
   if (!Compile("AliFMDAnaFlowKine.C")) return;
   AliFMDAnaFlowKine ak(1, segmented, primary_only); 
index 510b059..abcce7d 100644 (file)
@@ -747,10 +747,10 @@ void HmpConfig::WriteConfig()
   fprintf(pF,"  gAlice->SetRunLoader(pAL);\n\n");
 //Decayer  
   if(fDecayerB->GetState()==kButtonDown){
-    fprintf(pF,"  gSystem->Load(\"liblhapdf.so\"); // Parton density functions \n");
-    fprintf(pF,"  gSystem->Load(\"libEGPythia6.so\");   // TGenerator interface \n");
-    fprintf(pF,"  gSystem->Load(\"libpythia6.so\");   // Pythia \n");
-    fprintf(pF,"  gSystem->Load(\"libAliPythia6.so\");   // ALICE specifics implementations \n\n");
+    fprintf(pF,"  gSystem->Load(\"liblhapdf\"); // Parton density functions \n");
+    fprintf(pF,"  gSystem->Load(\"libEGPythia6\");   // TGenerator interface \n");
+    fprintf(pF,"  gSystem->Load(\"libpythia6\");   // Pythia \n");
+    fprintf(pF,"  gSystem->Load(\"libAliPythia6\");   // ALICE specifics implementations \n\n");
 //Geant  
     fprintf(pF,"  gSystem->Load(\"libgeant321\");\n");
     fprintf(pF,"  new TGeant3TGeo(\"C++ Interface to Geant3\");\n\n");
index 87e7c1f..f163aff 100644 (file)
@@ -246,7 +246,7 @@ pluginHandler = pluginManager->FindHandler("AliReconstructor", "ITS");
   if (!pluginHandler) {
     printf("defining plugin for ITS\n");
     TString libs = gSystem->GetLibraries();
-    if (libs.Contains("lib" + detName + "base.so") ||
+    if (libs.Contains("lib" + detName + "base") ||
        (gSystem->Load("lib" + detName + "base") >= 0)) {pluginManager->AddHandler("AliReconstructor", detName,recName, detName + "rec", recName + "()");}
     else {pluginManager->AddHandler("AliReconstructor", detName,recName, detName, recName + "()");}
     pluginHandler = pluginManager->FindHandler("AliReconstructor", detName);
index a60c658..35b82cf 100644 (file)
@@ -26,9 +26,7 @@ void RunSingleMuonAnalysisFromAOD(Int_t mode=kMlocal, Char_t *inputPath=".", Cha
   timer.Start();
 
   // Check if user is running root or aliroot
-  TString checkString = gSystem->Getenv("ALICE_ROOT");
-  checkString.Append("/lib/tgt_linux/libSTEERBase.so");
-  TString foundLib = gSystem->GetLibraries(checkString.Data());
+  TString foundLib = gSystem->GetLibraries( "libSTEERBase", "", kFALSE );
   Bool_t isFullAliroot = (foundLib.Length()==0) ? kFALSE : kTRUE;
 
   // Load libraries
index 86dec62..328af22 100644 (file)
@@ -3,7 +3,7 @@ void readTTree()
 
     // example macro to read data from a ttree and perform a flow analysis using the flow pacakge
     // author: Redmer Alexander Bertens (rbertens@cern.ch)
-    // note: this macro can run in ROOT only provided libPWGflowBase.so is available
+    // note: this macro can run in ROOT only provided libPWGflowBase is available
 
     // compile the relevant classes
     // include paths, necessary for compilation
index c5a7246..2b1ccfc 100644 (file)
@@ -257,7 +257,7 @@ void LoadLibrariesFQD(const libModes mode) {
   gSystem->AddIncludePath("-I$ALICE_ROOT/include");
   gSystem->Load("libANALYSIS");
   gSystem->Load("libPWGflowBase");
-  cerr<<"libPWGflowBase.so loaded ..."<<endl;
+  cerr<<"libPWGflowBase loaded ..."<<endl;
   
   }
   
index 08b7bed..08c0b26 100644 (file)
@@ -43,9 +43,12 @@ void setupPi0Flow(const char* localAodDirectory, int nFiles, const char* lhcPeri
   gSystem->AddIncludePath(includePath);
   TString libraries=libraryDependencies;
   TObjArray* pTokens=libraries.Tokenize(" ");
+  TString buf;
   if (pTokens) {
     for (int i=0; i<pTokens->GetEntriesFast(); i++) {
-      if (gSystem->Load(pTokens->At(i)->GetName())==0) {
+      buf = pTokens->At(i)->GetName();
+      buf.ReplaceAll(".so", "");
+      if (gSystem->Load(buf)==0) {
        cout << "loading " << pTokens->At(i)->GetName() << endl;
       }
     }
index 519a284..aae9c1c 100644 (file)
@@ -330,13 +330,16 @@ void run_single_task(const char* mode,
     }
   }
   TObjArray* pTokens=libraries.Tokenize(" ");
+  TString buf;
   if (pTokens) {
     for (int i=0; i<pTokens->GetEntriesFast(); i++) {
       TString library=pTokens->At(i)->GetName();
       if (!library.EndsWith(".so")) {
        cerr << "libraries need to have ending '.so' in order to be correctly processed by alien plugin, please correct library name '" << library << "'" << endl;
       }
-      if (gSystem->Load(pTokens->At(i)->GetName())==0) {
+      buf = pTokens->At(i)->GetName();
+      buf.ReplaceAll(".so", "");
+      if (gSystem->Load(buf)==0) {
        cout << "loading " << pTokens->At(i)->GetName() << endl;
       }
     }
index d406b1f..1617040 100644 (file)
@@ -59,9 +59,12 @@ void setupDxHFE(const char* localAodDirectory, int nofDirectories, const char* l
   gSystem->AddIncludePath(includePath);
   TString libraries=libraryDependencies;
   TObjArray* pTokens=libraries.Tokenize(" ");
+  TString buf;
   if (pTokens) {
     for (int i=0; i<pTokens->GetEntriesFast(); i++) {
-      if (gSystem->Load(pTokens->At(i)->GetName())==0) {
+      buf = pTokens->At(i)->GetName();
+      buf.ReplaceAll(".so", "");
+      if (gSystem->Load(buf)==0) {
        cout << "loading " << pTokens->At(i)->GetName() << endl;
       }
     }
index 73babf5..600f79e 100644 (file)
@@ -2,29 +2,29 @@
 // Base macro for submitting muon Resolution analysis.
 //
 // In case it is not run with full aliroot, it needs the following libraries:
-//  - libSTEERBase.so
-//  - libESD.so
-//  - libAOD.so
-//  - libANALYSIS.so
-//  - libANALYSISalice.so
-//  - libGui.so
-//  - libMinuit.so
-//  - libProofPlayer.so
-//  - libXMLParser.so
-//  - libRAWDatabase.so
-//  - libCDB.so
-//  - libSTEER.so
-//  - libMUONcore.so
-//  - libMUONmapping.so
-//  - libMUONcalib.so
-//  - libMUONgeometry.so
-//  - libMUONtrigger.so
-//  - libMUONraw.so
-//  - libMUONbase.so
-//  - libMUONrec.so
-//  - libCORRFW.so
-//  - libPWGHFbase.so
-//  - libPWGmuondep.so
+//  - libSTEERBase
+//  - libESD
+//  - libAOD
+//  - libANALYSIS
+//  - libANALYSISalice
+//  - libGui
+//  - libMinuit
+//  - libProofPlayer
+//  - libXMLParser
+//  - libRAWDatabase
+//  - libCDB
+//  - libSTEER
+//  - libMUONcore
+//  - libMUONmapping
+//  - libMUONcalib
+//  - libMUONgeometry
+//  - libMUONtrigger
+//  - libMUONraw
+//  - libMUONbase
+//  - libMUONrec
+//  - libCORRFW
+//  - libPWGHFbase
+//  - libPWGmuondep
 //
 // It also needs to load magnetic field, mapping, geometry (+alignment), and reconstruction parameters from the OCDB
 //
index 088e775..aa4b7c4 100644 (file)
@@ -2,13 +2,13 @@
 // Macro for QA monitoring.
 //
 // In case it is not run with full aliroot, it needs the following libraries to compile:
-//  - libSTEERBase.so
-//  - libESD.so
-//  - libAOD.so
-//  - libANALYSIS.so
-//  - libANALYSISalice.so
-//  - libCORRFW.so
-//  - libPWGmuon.so
+//  - libSTEERBase
+//  - libESD
+//  - libAOD
+//  - libANALYSIS
+//  - libANALYSISalice
+//  - libCORRFW
+//  - libPWGmuon
 //
 // TString includePath = "-I${ALICE_ROOT}/PWGmuon ";  gSystem->SetIncludePath(includePath.Data());
 //
index efbc65c..ef42f34 100644 (file)
@@ -2,13 +2,13 @@
 // Base macro for submitting muon QA analysis.
 //
 // In case it is not run with full aliroot, it needs the following libraries:
-//  - libSTEERBase.so
-//  - libESD.so
-//  - libAOD.so
-//  - libANALYSIS.so
-//  - libANALYSISalice.so
-//  - libCORRFW.so
-//  - libPWGmuon.so
+//  - libSTEERBase
+//  - libESD
+//  - libAOD
+//  - libANALYSIS
+//  - libANALYSISalice
+//  - libCORRFW
+//  - libPWGmuon
 //
 // The macro reads ESDs and store outputs in standard output file (AnalysisResults.root)
 //
index fcea0f6..4eef859 100644 (file)
@@ -164,7 +164,7 @@ void completeProd(TString runListName="runList.txt", TString prodDir = "", TStri
   ofstream outFile(outFilename.Data());
 
   const Int_t kNlibs = 5; // 1
-  TString loadLibs[kNlibs] = {"libANALYSIS.so", "libOADB.so", "libANALYSISalice.so", "libCORRFW.so", "libPWGmuon.so"};
+  TString loadLibs[kNlibs] = {"libANALYSIS", "libOADB", "libANALYSISalice", "libCORRFW", "libPWGmuon"};
   for ( Int_t ilib=0; ilib<kNlibs; ilib++ ) {
     Int_t exitVal = gSystem->Load(loadLibs[ilib].Data());
     if ( exitVal < 0 ) {
index 803b1d8..2fe1548 100644 (file)
@@ -109,7 +109,7 @@ void terminateQA(TString outfilename = "QAresults.root", Bool_t force = kFALSE,
   gSystem->Load("libPhysics");
   gSystem->Load("libProof");
 
-  TString libsList = "libANALYSIS.so libOADB.so libANALYSISalice.so libCORRFW.so libPWGHFbase.so libPWGmuon.so libPWGPPMUONlite.so";
+  TString libsList = "libANALYSIS libOADB libANALYSISalice libCORRFW libPWGHFbase libPWGmuon libPWGPPMUONlite";
 
   TObjArray* libsArray = libsList.Tokenize(" ");
   libsArray->SetOwner();
index 996eb4e..d24afc1 100644 (file)
@@ -66,7 +66,7 @@
 
 #endif
 
-Char_t const *libs[] = {"libProofPlayer.so", "libANALYSIS.so", "libANALYSISalice.so", "libTender.so", "libSTAT.so", "libPWGPP.so", "libPWGmuon.so"};
+Char_t const *libs[] = {"libProofPlayer", "libANALYSIS", "libANALYSISalice", "libTender", "libSTAT", "libPWGPP", "libPWGmuon"};
 
 // define setup
 TClass *ctask = new TClass;
index 459ae1c..8f40234 100644 (file)
@@ -82,7 +82,7 @@
 #include "PWGPP/TRD/AliTRDinfoGen.h"
 #endif
 
-const Char_t *libs[] = {"libProofPlayer.so", "libANALYSIS.so", "libANALYSISalice.so", "libCORRFW", "libTender.so", "libPWGPP.so", "libPWGmuon.so"};
+const Char_t *libs[] = {"libProofPlayer", "libANALYSIS", "libANALYSISalice", "libCORRFW", "libTender", "libPWGPP", "libPWGmuon"};
 // define setup
 TCanvas *c(NULL);
 Bool_t mc(kFALSE), friends(kFALSE);
index e0031c2..9adef36 100644 (file)
   TProof::Open("");
   .L /u/miranov/macros/ProofEnableAliRoot.C
   ProofEnableAliRoot("/usr/local/grid/AliRoot/HEAD0108");
-  gProof->Exec("gSystem->Load(\"libANALYSIS.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libAOD.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libANALYSISalice.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libPWG0base.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libPWG0dep.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libPWGPP.so\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libANALYSIS\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libAOD\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libANALYSISalice\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libPWG0base\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libPWG0dep\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libPWGPP\")",kTRUE);
   
   TString path=gSystem->pwd();
   TString execCDB="gROOT->Macro(\"";
index af4080c..0643e32 100644 (file)
@@ -109,7 +109,7 @@ performAllPi(){
   doeffPi(0,0.1,etamin,etamax);
   kOverAll2Sigma=kFALSE;
   kOverAll=kFALSE;
-  gSystem->Unload("$ALICE_ROOT/PWGPP/pid/doeffPi_C.so");
+  gSystem->Unload("$ALICE_ROOT/PWGPP/pid/doeffPi_C");
 }
 
 performAllPr(){
@@ -217,7 +217,7 @@ performAllPr(){
   doeffPr(0,0.1,etamin,etamax);
   kOverAll2Sigma=kFALSE;
   kOverAll=kFALSE;
-  gSystem->Unload("$ALICE_ROOT/PWGPP/pid/doeffPr_C.so");
+  gSystem->Unload("$ALICE_ROOT/PWGPP/pid/doeffPr_C");
 }
 
 performAllKa(){
@@ -325,7 +325,7 @@ performAllKa(){
   doeffKa(0,0.1,etamin,etamax);
   kOverAll2Sigma=kFALSE;
   kOverAll=kFALSE;
-  gSystem->Unload("$ALICE_ROOT/PWGPP/pid/doeffKa_C.so");
+  gSystem->Unload("$ALICE_ROOT/PWGPP/pid/doeffKa_C");
 }
 
 TGraphErrors *MakeRatio(const char *nf1,const char *nf2,const char *nfo=""/*output file*/,const char *title=""/*title*/){
index 0ec2dda..cc4fa39 100644 (file)
@@ -31,9 +31,9 @@
   proof->SetParameter("PROOF_MaxSlavesPerNode", (Long_t)1000);
   .L /u/miranov/macros/ProofEnableAliRoot.C
   ProofEnableAliRoot("/usr/local/grid/AliRoot/HEAD0108");
-  gProof->Exec("gSystem->Load(\"libANALYSIS.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libSTAT.so\")",kTRUE);
-  gProof->Exec("gSystem->Load(\"libTPCcalib.so\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libANALYSIS\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libSTAT\")",kTRUE);
+  gProof->Exec("gSystem->Load(\"libTPCcalib\")",kTRUE);
   gProof->Exec(".x $ALICE_ROOT/TPC/macros/ConfigOCDB.C");
 
   //
index 6119cb9..c8046f9 100644 (file)
@@ -41,7 +41,7 @@ Int_t loadlibs ()
   if ( gSystem->Load("libSTAT") < 0 ) return ret; ret--;
 
   if ( gSystem->Load("libhijing") < 0 ) return ret; ret--;
-  if ( gSystem->Load("libTHijing") < 0 ) return ret; ret--;// AliGenHijingEventHeader needed by libZDCsim.so
+  if ( gSystem->Load("libTHijing") < 0 ) return ret; ret--;// AliGenHijingEventHeader needed by libZDCsim
 
   if ( gSystem->Load("libSTRUCT") < 0 ) return ret; ret--;
   if ( gSystem->Load("libPHOSUtils") < 0 ) return ret; ret--;
index 2c94d3c..cc73730 100644 (file)
@@ -41,7 +41,7 @@ Int_t loadlibssim ()
   if ( gSystem->Load("libAliPythia6") < 0 ) return ret; ret--;
 
   if ( gSystem->Load("libhijing") < 0 ) return ret; ret--;
-  if ( gSystem->Load("libTHijing") < 0 ) return ret; ret--;// AliGenHijingEventHeader needed by libZDCsim.so
+  if ( gSystem->Load("libTHijing") < 0 ) return ret; ret--;// AliGenHijingEventHeader needed by libZDCsim
 
   if ( gSystem->Load("libSTRUCT") < 0 ) return ret; ret--;
   if ( gSystem->Load("libPHOSUtils") < 0 ) return ret; ret--;