Changes for Root6 (Mikolaj)
authorhristov <Peter.Hristov@cern.ch>
Tue, 3 Mar 2015 13:32:46 +0000 (14:32 +0100)
committerhristov <Peter.Hristov@cern.ch>
Tue, 3 Mar 2015 13:33:10 +0000 (14:33 +0100)
AD/ADsim/AliADDigitizer.cxx
EPOS/epos167/CMakeLists.txt
EVGEN/AliGenGeVSim.cxx
HLT/BASE/AliHLTCTPData.cxx
LHAPDF/lhapdf-5.9.1/CMakeLists.txt
PYTHIA6/pythia6.4.21/CMakeLists.txt
PYTHIA6/pythia6.4.25/CMakeLists.txt
RAW/RAWDatabase/RAWDatabaseLinkDef.h
TPC/TPCcalib/AliTPCcalibAlign.cxx
cmake/CMakeALICE.cmake

index 2dcdb4d..9e2ee69 100644 (file)
@@ -151,15 +151,14 @@ Bool_t AliADDigitizer::Init()
 
   // check if the digitizer was already initialized
   if (fSignalShape) return kTRUE;
-
   fSignalShape = new TF1("ADSignalShape",this,&AliADDigitizer::SignalShape,0,200,6,"AliADDigitizer","SignalShape");
+  fPMResponse = new TF1("ADPMResponse",this,&AliADDigitizer::PMResponse,-kPMRespTime,2.*kPMRespTime,0,"AliADDigitizer","PMResponse");
+  fSinglePhESpectrum = new TF1("ADSinglePhESpectrum",this,&AliADDigitizer::SinglePhESpectrum,0,20,0,"AliADDigitizer","SinglePhESpectrum");
   //  fSignalShape->SetParameters(0,1.57345e1,-4.25603e-1,2.9,6.40982,3.69339e-01);
   //  fSignalShape->SetParameters(1.34330e+00,1.13007e+02,-4.95705e-01,
   //                         3.68911e+00,1.01040e+00, 3.94675e-01);
   fSignalShape->SetParameters(-1.07335e+00,2.16002e+01,-1.26133e-01,
                              1.41619e+00,5.50334e-01,3.86111e-01);
-  fPMResponse = new TF1("ADPMResponse",this,&AliADDigitizer::PMResponse,-kPMRespTime,2.*kPMRespTime,0,"AliADDigitizer","PMResponse");
-  fSinglePhESpectrum = new TF1("ADSinglePhESpectrum",this,&AliADDigitizer::SinglePhESpectrum,0,20,0,"AliADDigitizer","SinglePhESpectrum");
   
   // Now get the CTP L0->L1 delay
   AliCDBEntry *entry = AliCDBManager::Instance()->Get("GRP/CTP/CTPtiming");
index b501eca..57ef4d2 100644 (file)
@@ -17,7 +17,8 @@
 set(MODULE EPOS)
 
 # Module include folder
-include_directories(${AliRoot_SOURCE_DIR}/EPOS/epos167
+include_directories(${AliRoot_SOURCE_DIR}/EPOS
+                    ${AliRoot_SOURCE_DIR}/EPOS/epos167
                    )
 
 # Additional include folders in alphabetical order
index 7204daa..b22b588 100644 (file)
@@ -63,7 +63,7 @@
 //
 ////////////////////////////////////////////////////////////////////////////////
 
-
+#include <RVersion.h>
 #include <Riostream.h>
 #include <TCanvas.h>
 #include <TF1.h>
@@ -568,8 +568,13 @@ void AliGenGeVSim::SetFormula(Int_t pdg) {
 
   // standard models
 
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+  if (fModel == 1) fCurrentForm = fPtFormula->GetFormula();
+  if (fModel > 1 && fModel < 5) fCurrentForm = fPtYFormula[fModel-2]->GetFormula();
+#else
   if (fModel == 1) fCurrentForm = fPtFormula;
   if (fModel > 1 && fModel < 5) fCurrentForm = fPtYFormula[fModel-2];
+#endif
 
 
   // custom model defined by a formula 
@@ -577,12 +582,22 @@ void AliGenGeVSim::SetFormula(Int_t pdg) {
   if (fModel == 5) {
     
     fCurrentForm = 0;
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+    TF2* tmpTF2 = (TF2*)gROOT->GetFunction(pattern[0]);
+    if (tmpTF2) fCurrentForm = tmpTF2->GetFormula();
+#else
     fCurrentForm = (TF2*)gROOT->GetFunction(pattern[0]);
+#endif
     
     if (!fCurrentForm) {
 
       snprintf(buff, 40, pattern[1], pdg);
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+      tmpTF2 = (TF2*)gROOT->GetFunction(buff);
+      if (tmpTF2) fCurrentForm = tmpTF2->GetFormula();
+#else
       fCurrentForm = (TF2*)gROOT->GetFunction(buff);
+#endif
 
       if (!fCurrentForm) Error(where, msg[0], pdg);
     }
index bae38fd..6f61f7d 100644 (file)
@@ -30,6 +30,7 @@
 #include "AliHLTCDHWrapper.h"
 #include <limits>
 #include <sstream>
+#include <RVersion.h>
 
 /** ROOT macro for the implementation of ROOT specific class methods */
 ClassImp(AliHLTCTPData)
@@ -299,7 +300,11 @@ bool AliHLTCTPData::EvaluateCTPTriggerClass(const char* expression, AliHLTTrigge
   }
 
   TFormula form("trigger expression", condition);
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+  if (form.IsValid()!=0) {
+#else
   if (form.Compile()!=0) {
+#endif
     HLTError("invalid expression %s", expression);
     return false;
   }
index 4e38ee9..0e50c7c 100644 (file)
@@ -14,7 +14,7 @@
 # **************************************************************************
 
 # Module
-set(MODULE lhapdf-5_9_1)
+set(MODULE lhapdf_5_9_1)
 
 # Module include folder
 include_directories(${AliRoot_SOURCE_DIR}/LHAPDF/lhapdf-5.9.1
index 78202e1..1dbfb0b 100644 (file)
 # **************************************************************************
 
 # Module
-set(MODULE pythia6.4.21)
+set(MODULE pythia6_4_21)
 
 # Module include folder
-include_directories(${AliRoot_SOURCE_DIR}/PYTHIA6/${MODULE})
+include_directories(${AliRoot_SOURCE_DIR}/PYTHIA6/pythia6.4.21)
 
 # Additional include folders in alphabetical order except ROOT
 include_directories(${ROOT_INCLUDE_DIR}
index bfc4e99..bfbb9ab 100644 (file)
 # **************************************************************************
 
 # Module
-set(MODULE pythia6.4.25)
+set(MODULE pythia6_4_25)
 
 # Module include folder
-include_directories(${AliRoot_SOURCE_DIR}/PYTHIA6/${MODULE})
+include_directories(${AliRoot_SOURCE_DIR}/PYTHIA6/pythia6.4.25)
 
 # Additional include folders in alphabetical order except ROOT
 include_directories(${ROOT_INCLUDE_DIR}
index 3d6ec77..30ea47f 100644 (file)
@@ -1,4 +1,5 @@
 #ifdef __CINT__
+#include <RVersion.h>
 
 #pragma link off all globals;
 #pragma link off all classes;
@@ -8,7 +9,6 @@
 #pragma link C++ class AliRawEvent-;
 #pragma link C++ class AliRawEventV2+;
 #pragma link C++ class AliRawEventHeaderBase+;
-#pragma link C++ defined_in AliRawEventHeaderVersions.h;
 #pragma link C++ class AliRawEquipmentHeader;
 #pragma link C++ class AliRawVEquipment+;
 #pragma link C++ class AliRawEquipment-;
 #pragma link C++ class AliAltroMapping+;
 #pragma link C++ class AliCaloAltroMapping+;
 
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+#pragma link C++ class AliRawEventHeaderV3_11+;
+#pragma link C++ class AliRawEventHeaderV3_12+;
+#pragma link C++ class AliRawEventHeaderV3_13+;
+#pragma link C++ class AliRawEventHeaderV3_9+;
+#pragma link C++ class AliRawEventHeaderV3_14+;
+#else
+#pragma link C++ defined_in AliRawEventHeaderVersions.h;
+#endif
+
 #endif
index b9ed7d3..e0b4880 100644 (file)
 #include "TTreeStream.h"
 #include "Riostream.h"
 #include "TRandom.h"
+#include <RVersion.h>
 #include <sstream>
 
 #include "AliSysInfo.h"
@@ -1478,7 +1479,11 @@ TLinearFitter* AliTPCcalibAlign::GetOrMakeFitter12(Int_t s1,Int_t s2) {
   TLinearFitter * fitter = GetFitter12(s1,s2);
   if (fitter) return fitter;
   //  fitter =new TLinearFitter(12,"x[0]++x[1]++x[2]++x[3]++x[4]++x[5]++x[6]++x[7]++x[8]++x[9]++x[10]++x[11]");
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+  fitter =new TLinearFitter(f12.GetFormula(),"");
+#else
   fitter =new TLinearFitter(&f12,"");
+#endif
   fitter->StoreData(kFALSE);
   fFitterArray12.AddAt(fitter,GetIndex(s1,s2));        
   counter12++;
@@ -1495,7 +1500,11 @@ TLinearFitter* AliTPCcalibAlign::GetOrMakeFitter9(Int_t s1,Int_t s2) {
   TLinearFitter * fitter = GetFitter9(s1,s2);
   if (fitter) return fitter;
   //  fitter =new TLinearFitter(9,"x[0]++x[1]++x[2]++x[3]++x[4]++x[5]++x[6]++x[7]++x[8]");
+#if ROOT_VERSION_CODE >= ROOT_VERSION(5,99,0)
+  fitter =new TLinearFitter(f9.GetFormula(),"");
+#else
   fitter =new TLinearFitter(&f9,"");
+#endif
   fitter->StoreData(kFALSE);
   fFitterArray9.AddAt(fitter,GetIndex(s1,s2));
   counter9++;
index 60a12b4..3307304 100644 (file)
@@ -53,18 +53,22 @@ macro(generate_dictionary DNAME LDNAME DHDRS DINCDIRS)
                        WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
                       )
     else (ROOT_VERSION_MAJOR LESS 6)
-    add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/lib${DNAME}.rootmap ${CMAKE_CURRENT_BINARY_DIR}/G__${DNAME}.cxx
+      add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/lib${DNAME}.rootmap ${CMAKE_CURRENT_BINARY_DIR}/G__${DNAME}.cxx ${CMAKE_CURRENT_BINARY_DIR}/G__${DNAME}_rdict.pcm
                        COMMAND
                          LD_LIBRARY_PATH=${ROOT_LIBDIR}:$ENV{LD_LIBRARY_PATH} ${ROOT_CINT}
                        ARGS
                          -f ${CMAKE_CURRENT_BINARY_DIR}/G__${DNAME}.cxx
                          -rmf ${CMAKE_CURRENT_BINARY_DIR}/lib${DNAME}.rootmap -rml lib${DNAME}
-                         ${GLOBALDEFINITIONS} ${EXTRADEFINITIONS}  ${INCLUDE_PATH} ${DHDRS} ${LDNAME}
+                         ${GLOBALDEFINITIONS} ${EXTRADEFINITIONS} ${INCLUDE_PATH} ${DHDRS} ${LDNAME}
                        DEPENDS
                          ${DHDRS} ${LDNAME} ${ROOT_CINT}
                        WORKING_DIRECTORY
                          ${CMAKE_CURRENT_BINARY_DIR}
                       )
+
+    install(FILES "${CMAKE_CURRENT_BINARY_DIR}/lib${DNAME}.rootmap" DESTINATION lib)
+    install(FILES "${CMAKE_CURRENT_BINARY_DIR}/G__${DNAME}_rdict.pcm" DESTINATION lib)
+    
     endif (ROOT_VERSION_MAJOR LESS 6)
 
 endmacro(generate_dictionary)