Index: trunk/LMDZ.COMMON/libf/dyn3dpar/gcm.F
===================================================================
--- trunk/LMDZ.COMMON/libf/dyn3dpar/gcm.F	(revision 3510)
+++ trunk/LMDZ.COMMON/libf/dyn3dpar/gcm.F	(revision 3574)
@@ -27,4 +27,5 @@
      &                       ecritstart
       use cpdet_mod, only: ini_cpdet
+      use version_info_mod, only: print_version_info
 
 
@@ -134,4 +135,5 @@
       character (len=20) :: modname
       character (len=80) :: abort_message
+      character(100)     :: arg ! To read command-line arguments
 ! locales pour gestion du temps
       INTEGER :: an, mois, jour
@@ -156,4 +158,16 @@
 c   Initialisations:
 c   ----------------
+
+      if (command_argument_count() > 0) then ! Get the number of command-line arguments
+          call get_command_argument(1,arg) ! Read the argument given to the program
+          select case (trim(adjustl(arg)))
+              case('version')
+                  call print_version_info()
+                  stop
+              case default
+                  error stop 'The argument given to the program '
+     &//'is unknown!'
+          end select
+      endif
 
       abort_message = 'last timestep reached'
