]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Added PAR stuff for PWG2forward2
authorcholm <cholm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 25 Nov 2010 16:41:57 +0000 (16:41 +0000)
committercholm <cholm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 25 Nov 2010 16:41:57 +0000 (16:41 +0000)
PWG2/PROOF-INF.PWG2forward2/BUILD.sh [new file with mode: 0755]
PWG2/PROOF-INF.PWG2forward2/SETUP.C [new file with mode: 0644]

diff --git a/PWG2/PROOF-INF.PWG2forward2/BUILD.sh b/PWG2/PROOF-INF.PWG2forward2/BUILD.sh
new file mode 100755 (executable)
index 0000000..bf10f72
--- /dev/null
@@ -0,0 +1,9 @@
+#! /bin/sh
+
+#touch libPWG2.pkg
+#touch libPWG2flow.pkg
+#touch libPWG2ebye.pkg
+#touch libPWG2femtoscopy.pkg
+#touch libPWG2femtoscopyUser.pkg
+
+make libPWG2forward2.so
diff --git a/PWG2/PROOF-INF.PWG2forward2/SETUP.C b/PWG2/PROOF-INF.PWG2forward2/SETUP.C
new file mode 100644 (file)
index 0000000..3979823
--- /dev/null
@@ -0,0 +1,18 @@
+void SETUP() {
+  CheckLoadLibrary("libPWG2forward2");
+
+  // Set the include paths
+  gROOT->ProcessLine(".include PWG2forward/FORWARD/analysis2");
+
+  // Set our location, so that other packages can find us
+  gSystem->Setenv("PWG2forward_INCLUDE", "PWG2forward/FORWARD/analysis2");
+}
+
+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);
+}