]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ALIROOT/aliroot.cxx
Extracting Branch and Revision from Git.
[u/mrichter/AliRoot.git] / ALIROOT / aliroot.cxx
index d29e66187af7004a6990c4e648628d81befca6bc..45766035769d9c7173cac9aab23472de7769e9fc 100644 (file)
@@ -37,6 +37,8 @@
 #include <TRint.h>
 #include <TFile.h>
 #include <AliRun.h>
+#include "Riostream.h"
+#include "ARVersion.h"
 
 #if defined __linux
 //On linux Fortran wants this, so we give to it!
@@ -44,12 +46,19 @@ int xargv=0;
 int xargc=0;
 #endif
 
+#ifdef FORTRAN_G95
+extern "C" void g95_runtime_start();
+#endif
+
 #if defined WIN32 
   extern "C" int __fastflag=0; 
   extern "C" int _pctype=0; 
   extern "C" int __mb_cur_max=0; 
 #endif 
 
+using std::cout;
+using std::endl;
+
 //_____________________________________________________________________________
 int main(int argc, char **argv)
 {
@@ -66,6 +75,17 @@ int main(int argc, char **argv)
   // run and event number, the number of vertices, tracks and primary tracks
   // in the event.
   
+  for ( int i = 1; i < argc; ++i ) 
+  {
+    TString argument(argv[i]);
+    
+    if (argument=="--version")
+    {      
+      cout << "aliroot " << ALIROOT_REVISION << " " << ALIROOT_BRANCH << endl;
+      return 0;
+    }    
+  }
+  
   // Create new configuration 
   
   new AliRun("gAlice","The ALICE Off-line Simulation Framework");
@@ -73,6 +93,9 @@ int main(int argc, char **argv)
   // Start interactive geant
   
   TRint *theApp = new TRint("aliroot", &argc, argv);
+#ifdef FORTRAN_G95
+  g95_runtime_start();
+#endif
   
   // --- Start the event loop ---
   theApp->Run();