Index: trunk/LMDZ.GENERIC/libf/phystd/physiq_mod.F90
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/physiq_mod.F90	(revision 2631)
+++ trunk/LMDZ.GENERIC/libf/phystd/physiq_mod.F90	(revision 2632)
@@ -710,5 +710,5 @@
          write(*,*) "physiq: call initialize_xios_output"
          call initialize_xios_output(pday,ptime,ptimestep,daysec, &
-                                     presnivs,pseudoalt)
+                                     year_day,presnivs,pseudoalt)
 #endif
          write(*,*) "physiq: end of firstcall"
Index: trunk/LMDZ.GENERIC/libf/phystd/xios_output_mod.F90
===================================================================
--- trunk/LMDZ.GENERIC/libf/phystd/xios_output_mod.F90	(revision 2631)
+++ trunk/LMDZ.GENERIC/libf/phystd/xios_output_mod.F90	(revision 2632)
@@ -18,5 +18,5 @@
 
   SUBROUTINE initialize_xios_output(day,timeofday,dtphys,daysec,&
-                                    presnivs,pseudoalt)
+                                    yearday,presnivs,pseudoalt)
 !  USE mod_phys_lmdz_para, only: gather, bcast, &
 !                                jj_nb, jj_begin, jj_end, ii_begin, ii_end, &
@@ -40,5 +40,6 @@
   REAL,INTENT(IN) :: timeofday ! "Universal time", given as fraction of sol (e.g.: 0.5 for noon).
   REAL,INTENT(IN) :: dtphys ! physics time step (s)
-  REAL,INTENT(IN) :: daysec ! lengthof a standard day (s)
+  REAL,INTENT(IN) :: daysec ! length of a standard day (s)
+  REAL,INTENT(IN) :: yearday ! length of a standard year (day)
   REAL,INTENT(IN) :: presnivs(:) ! vertical grid approximate pressure (Pa)
   REAL,INTENT(IN) :: pseudoalt(:) ! vertical grid approximate altitude (km)
@@ -104,5 +105,5 @@
      write(lunout,*) "initialize_xios_output: build calendar"
     endif
-    timestep%second=dtphys
+    timestep%second=1 !dtphys
     if (nint(dtphys).ne.dtphys) then
       write(*,*) "initialize_xios_output: warning physics timestep is not an integer!"
@@ -115,6 +116,7 @@
     CALL xios_define_calendar(type="user_defined", &
                               timestep=timestep, &
-                              day_length=nint(daysec), &
-                              month_lengths=[30,30,30,30,30,30,30,30,30,30,30,30])
+                              day_length=nint(daysec/dtphys), &
+                              month_lengths=[int(yearday)])
+                              !month_lengths=[30,30,30,30,30,30,30,30,30,30,30,30])
     !NB: it would make more sense to define months and their length in the
     ! xml files and not to have them hard coded here.... to be improved...
