5dd4e0e92d9511257ca94f20d1fb5164ad9882fb
[u/mrichter/AliRoot.git] / PWGLF / PROOF-INF.PWGLFresonances / SETUP.C
1 void SETUP()
2 {
3
4    gSystem->SetDynamicPath(Form("%s:%s", gSystem->pwd(), gSystem->GetDynamicPath()));
5    CheckLoadLibrary("libPWGLFresonances");
6
7    gROOT->ProcessLine(".include PWGLFresonances");
8    gROOT->ProcessLine(".include PWGLFresonances/RESONANCES");
9
10    // Set our location, so that other packages can find us
11    gSystem->Setenv("PWGLFresonances_INCLUDE", "PWGLFresonances/RESONANCES");
12 }
13
14 Int_t CheckLoadLibrary(const char* library)
15 {
16    // checks if a library is already loaded, if not loads the library
17
18    if (strlen(gSystem->GetLibraries(Form("%s.so", library), "", kFALSE)) > 0)
19       return 1;
20
21    return gSystem->Load(library);
22 }