Index: /LMDZ5/trunk/libf/phylmd/condsurf.F
===================================================================
--- /LMDZ5/trunk/libf/phylmd/condsurf.F	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/condsurf.F	(revision 1931)
@@ -55,5 +55,5 @@
       IF (jour.LT.0 .OR. jour.GT.(360-1)) THEN
          PRINT*,'Le jour demande n est pas correct: ', jour
-         CALL ABORT
+         CALL ABORT_gcm("condsurf", "", 1)
       ENDIF
 c
@@ -75,5 +75,5 @@
          PRINT *,' trouve pas sur les ',nannemax,' annees a partir de '
          PRINT *,' l annee de debut', annee_ref
-         CALL EXIT(1)
+         CALL abort_gcm("condsurf", "", 1)
 c
 100     CONTINUE
@@ -95,5 +95,5 @@
         WRITE(6,*)'       l an 2000 )  ,  n existe  pas !  ' 
         WRITE(6,*)' ierr = ', ierr
-        CALL EXIT(1)
+        CALL abort_gcm("condsurf", "", 1)
       ENDIF
 c     DO k = 1, jour
@@ -108,6 +108,5 @@
       ierr = NF_INQ_VARID (nid, "BILS", nvarid)
       IF (ierr .NE. NF_NOERR) THEN
-         PRINT*, "condsurf: Le champ <BILS> est absent"
-         CALL abort
+         CALL abort_gcm("cond_surf", "Le champ <BILS> est absent", 1)
       ENDIF
       PRINT*,'debut,epais',debut,epais,'jour,jourvrai',jour,jourvrai
@@ -118,6 +117,5 @@
 #endif
       IF (ierr .NE. NF_NOERR) THEN
-         PRINT*, "condsurf: Lecture echouee pour <BILS>"
-         CALL abort
+         CALL abort_gcm("condsurf", "Lecture echouee pour <BILS>", 1)
       ENDIF
 c     ENDDO !k = 1, jour
Index: /LMDZ5/trunk/libf/phylmd/iostart.F90
===================================================================
--- /LMDZ5/trunk/libf/phylmd/iostart.F90	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/iostart.F90	(revision 1931)
@@ -41,5 +41,5 @@
         write(6,*)' Pb d''ouverture du fichier '//filename
         write(6,*)' ierr = ', ierr
-        CALL ABORT
+        CALL ABORT_GCM("", "", 1)
       ENDIF
     ENDIF
@@ -166,5 +166,5 @@
       IF (.NOT. tmp_found) THEN
         PRINT*, 'phyetat0: Le champ <'//field_name//'> est absent'
-        CALL abort
+        call abort_gcm("", "", 1)
       ENDIF
     ENDIF
@@ -186,10 +186,10 @@
               IF (ierr/=NF90_NOERR) THEN
                  PRINT*, 'phyetat0: Lecture echouee aussi en 2D pour <'//field_name//'>'
-                 CALL abort
+                 call abort_gcm("", "", 1)
               ELSE
                  PRINT*, 'phyetat0: La variable <'//field_name//'> lu sur surface seulement'!, selon ancien format, le reste mis a zero'
               END IF
            ELSE
-              CALL abort
+              call abort_gcm("", "", 1)
            ENDIF
          ENDIF
@@ -282,5 +282,5 @@
         IF (ierr/=NF90_NOERR) THEN
           PRINT*, 'phyetat0: Lecture echouee pour <'//var_name//'>'
-          CALL abort
+          call abort_gcm("", "", 1)
         ENDIF
         tmp_found=.TRUE.
@@ -302,5 +302,5 @@
       IF (.NOT. tmp_found) THEN
         PRINT*, 'phyetat0: La variable champ <'//var_name//'> est absente'
-        CALL abort
+        call abort_gcm("", "", 1)
       ENDIF
     ENDIF
@@ -323,5 +323,5 @@
         write(6,*)' Pb d''ouverture du fichier '//filename
         write(6,*)' ierr = ', ierr
-        CALL ABORT
+        CALL ABORT_GCM("", "", 1)
       ENDIF
 
@@ -410,5 +410,5 @@
       ELSE
         PRINT *, "erreur phyredem : probleme de dimension"
-        CALL ABORT
+        CALL ABORT_GCM("", "", 1)
       ENDIF
          
@@ -487,5 +487,5 @@
       IF (var_size/=length) THEN
         PRINT *, "erreur phyredem : probleme de dimension"
-        CALL abort
+        call abort_gcm("", "", 1)
       ENDIF
       
Index: /LMDZ5/trunk/libf/phylmd/phyetat0.F90
===================================================================
--- /LMDZ5/trunk/libf/phylmd/phyetat0.F90	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/phyetat0.F90	(revision 1931)
@@ -206,5 +206,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -242,5 +242,5 @@
         IF (isoil.GT.99 .AND. nsrf.GT.99) THEN
            PRINT*, "Trop de couches ou sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str7, '(i2.2, "srf", i2.2)') isoil, nsrf
@@ -266,5 +266,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -321,5 +321,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -359,5 +359,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -425,5 +425,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -544,5 +544,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -582,5 +582,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
@@ -775,5 +775,5 @@
         IF (nsrf.GT.99) THEN
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyetat0", "", 1)
         ENDIF
         WRITE(str2, '(i2.2)') nsrf
Index: /LMDZ5/trunk/libf/phylmd/phyredem.F90
===================================================================
--- /LMDZ5/trunk/libf/phylmd/phyredem.F90	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/phyredem.F90	(revision 1931)
@@ -129,5 +129,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -141,5 +141,5 @@
         ELSE
            PRINT*, "Trop de couches"
-           CALL abort
+           call abort_gcm("phyredem", "", 1)
         ENDIF
      ENDDO
@@ -153,5 +153,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   END DO
@@ -166,5 +166,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -177,5 +177,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -188,5 +188,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -199,5 +199,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -222,5 +222,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -234,5 +234,5 @@
      ELSE
         PRINT*, "Trop de sous-mailles"
-        CALL abort
+        call abort_gcm("phyredem", "", 1)
      ENDIF
   ENDDO
@@ -285,5 +285,5 @@
         ELSE
            PRINT*, "Trop de sous-mailles"
-           CALL abort
+           call abort_gcm("phyredem", "", 1)
         ENDIF
      ENDDO
Index: /LMDZ5/trunk/libf/phylmd/physiq.F90
===================================================================
--- /LMDZ5/trunk/libf/phylmd/physiq.F90	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/physiq.F90	(revision 1931)
@@ -1153,5 +1153,5 @@
            IF(nCFMIP.GT.npCFMIP) THEN
               print*,'nCFMIP > npCFMIP : augmenter npCFMIP et recompiler'
-              CALL abort
+              call abort_gcm("physiq", "", 1)
            else
               print*,'physiq npCFMIP=',npCFMIP,'nCFMIP=',nCFMIP
@@ -1257,10 +1257,10 @@
      !$OMP BARRIER
 
-    freq_outNMC(1) = ecrit_files(7)
-    freq_outNMC(2) = ecrit_files(8)
-    freq_outNMC(3) = ecrit_files(9)
-    WRITE(lunout,*)'OK freq_outNMC(1)=',freq_outNMC(1)
-    WRITE(lunout,*)'OK freq_outNMC(2)=',freq_outNMC(2)
-    WRITE(lunout,*)'OK freq_outNMC(3)=',freq_outNMC(3)
+     freq_outNMC(1) = ecrit_files(7)
+     freq_outNMC(2) = ecrit_files(8)
+     freq_outNMC(3) = ecrit_files(9)
+     WRITE(lunout,*)'OK freq_outNMC(1)=',freq_outNMC(1)
+     WRITE(lunout,*)'OK freq_outNMC(2)=',freq_outNMC(2)
+     WRITE(lunout,*)'OK freq_outNMC(3)=',freq_outNMC(3)
 
      include "ini_histday_seri.h"
@@ -1692,12 +1692,12 @@
   ENDIF
 
-! AI Janv 2014 
-        do i = 1, klon
-         if (fract(i).le.0.) then
-            JrNt(i)=0.
-         else
-            JrNt(i)=1.
-         endif
-        enddo
+  ! AI Janv 2014 
+  do i = 1, klon
+     if (fract(i).le.0.) then
+        JrNt(i)=0.
+     else
+        JrNt(i)=1.
+     endif
+  enddo
 
   if (mydebug) then
@@ -2123,5 +2123,5 @@
   ELSE
      WRITE(lunout,*) "iflag_con non-prevu", iflag_con
-     CALL abort
+     call abort_gcm("physiq", "", 1)
   ENDIF
 
@@ -3250,5 +3250,4 @@
 
   ENDIF
-  !
 
   !
Index: /LMDZ5/trunk/libf/phylmd/radlwsw_m.F90
===================================================================
--- /LMDZ5/trunk/libf/phylmd/radlwsw_m.F90	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/radlwsw_m.F90	(revision 1931)
@@ -219,9 +219,9 @@
   IF (nb_gr*kdlon .NE. KLON) THEN
       PRINT*, "kdlon mauvais:", KLON, kdlon, nb_gr
-      CALL abort
+      call abort_gcm("radlwsw", "", 1)
   ENDIF
   IF (kflev .NE. KLEV) THEN
       PRINT*, "kflev differe de KLEV, kflev, KLEV"
-      CALL abort
+      call abort_gcm("radlwsw", "", 1)
   ENDIF
   !-------------------------------------------
@@ -334,5 +334,4 @@
 !===== iflag_rrtm ================================================
 !      
-    print*,'iflag_rrtm = ', iflag_rrtm
     IF (iflag_rrtm == 0) THEN
        ! Old radiation scheme, used for AR4 runs
Index: /LMDZ5/trunk/libf/phylmd/soil.F90
===================================================================
--- /LMDZ5/trunk/libf/phylmd/soil.F90	(revision 1930)
+++ /LMDZ5/trunk/libf/phylmd/soil.F90	(revision 1931)
@@ -178,5 +178,5 @@
   ELSE
      WRITE(lunout,*) "valeur d indice non prevue", indice
-     CALL abort
+     call abort_gcm("soil", "", 1)
   ENDIF
 
