]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
PAR: loading library in SETUP.C
authordberzano <dario.berzano@cern.ch>
Thu, 29 Jan 2015 10:27:31 +0000 (11:27 +0100)
committerdberzano <dario.berzano@cern.ch>
Thu, 29 Jan 2015 11:57:53 +0000 (12:57 +0100)
cmake/PARfiles/SETUP.C.in

index 033162adc98f1c64657983664fd6b1d648a98646..c8bf777e4e005456f592fbbfef4e1e496ff44acf 100644 (file)
@@ -20,11 +20,15 @@ Int_t SETUP()
 
   // Add our rootmap
   // TODO: disabled because it triggers actual library loading wherever it finds nested classes!
+  // (this is a ROOT bug)
   // buf.Form("%s/lib@PARMODULE@.rootmap", wd);
   // gInterpreter->UnloadLibraryMap("lib@PARMODULE@");
   // gInterpreter->LoadLibraryMap(buf.Data());
 
-  // Note: there is no need to actually load the library thanks to the rootmap
+  // Here we load the library, but beware: if using multiple PARfiles for overriding multiple
+  // AliRoot libraries, they must be loaded in the correct order. With the autoloading, it might
+  // happen that the *wrong* library gets loaded as a dependency
+  gSystem->Load("lib@PARMODULE@");
 
   return 0;
 }