Using the default ITS settings in the configuration files (Bjorn)
[u/mrichter/AliRoot.git] / macros / MakeAllDETsZeroMisAlignment.C
CommitLineData
d3a9c52a 1void MakeAllDETsZeroMisAlignment(Char_t* CDBstorage = "local://$HOME/Zero"){
2 // Make zero misalignment objects for all detectors
3 // Pass different "CDBstorage" argument if needed (e.g. to fill
4 // conditions' data base on alien) or set it to null string to have
5 // the objects saved locally on file
6 //
7 TString strStorage(CDBstorage);
8 if(strStorage.IsNull()){
5bd470e1 9 gSystem->Setenv("TOCDB","kFALSE");
d3a9c52a 10 }else{
5bd470e1 11 gSystem->Setenv("TOCDB","kTRUE");
12 gSystem->Setenv("STORAGE",strStorage.Data());
13 gSystem->Setenv("ARVERSION","v4-05-08");
d3a9c52a 14 }
15
dfe9c69d 16 if(!AliGeomManager::GetGeometry()){
17 if(!(AliCDBManager::Instance())->IsDefaultStorageSet())
18 AliCDBManager::Instance()->SetDefaultStorage("local://$ALICE_ROOT");
19 AliCDBManager::Instance()->SetRun(0);
20 AliGeomManager::LoadGeometry();
d3a9c52a 21 }
22
dfe9c69d 23
d3a9c52a 24 TString dets="EMCAL,FMD,HMPID,ITS,MUON,PMD,PHOS,T0,TRD,TPC,TOF,VZERO,ZDC";
25 TObjArray *detArray = dets.Tokenize(',');
26 TIter iter(detArray);
27 TObjString *ostr;
28 TString exec_det_macro;
29
30 while((ostr = (TObjString*) iter.Next())){
31 TString str(ostr->String());
32 exec_det_macro="aliroot -b -q $ALICE_ROOT/";
33 exec_det_macro+=str;
34 exec_det_macro+="/Make";
35 exec_det_macro+=str;
36 exec_det_macro+="ZeroMisAlignment.C";
37
38 gSystem->Exec(exec_det_macro.Data());
39 }
40
41 return;
42}