]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
PROOF-INF.PWG3base directory and SETUP.C and BUILD,sh files for the compilation of...
authormartinez <martinez@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 18 Oct 2007 12:54:29 +0000 (12:54 +0000)
committermartinez <martinez@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 18 Oct 2007 12:54:29 +0000 (12:54 +0000)
PWG3/PROOF-INF.PWG3base/BUILD.sh [new file with mode: 0755]
PWG3/PROOF-INF.PWG3base/SETUP.C [new file with mode: 0644]

diff --git a/PWG3/PROOF-INF.PWG3base/BUILD.sh b/PWG3/PROOF-INF.PWG3base/BUILD.sh
new file mode 100755 (executable)
index 0000000..d70052c
--- /dev/null
@@ -0,0 +1,2 @@
+#! /bin/sh
+make libPWG3base.so
diff --git a/PWG3/PROOF-INF.PWG3base/SETUP.C b/PWG3/PROOF-INF.PWG3base/SETUP.C
new file mode 100644 (file)
index 0000000..7bbafc6
--- /dev/null
@@ -0,0 +1,32 @@
+void SETUP()
+{
+    // Load some ROOT libraries
+    CheckLoadLibrary("libEG");
+    CheckLoadLibrary("libTree");
+    CheckLoadLibrary("libGeom");
+    CheckLoadLibrary("libVMC");
+
+    // Load the ESD library
+    CheckLoadLibrary("libANALYSIS");
+    CheckLoadLibrary("libSTEERBase");
+    CheckLoadLibrary("libESD");
+    CheckLoadLibrary("libAOD");
+    CheckLoadLibrary("libPWG3base");
+
+
+   // Set the include paths
+   gROOT->ProcessLine(".include PWG3base");
+
+   // Set our location, so that other packages can find us
+   gSystem->Setenv("PWG3base_INCLUDE", "PWG3base");
+}
+
+Int_t CheckLoadLibrary(const char* library)
+{
+  // checks if a library is already loaded, if not loads the library
+
+  if (strlen(gSystem->GetLibraries(Form("%s.so", library), "", kFALSE)) > 0)
+    return 1;
+
+  return gSystem->Load(library);
+}