Index: /LMDZ6/trunk/libf/dyn3d/guide_mod.F90
===================================================================
--- /LMDZ6/trunk/libf/dyn3d/guide_mod.F90	(revision 5070)
+++ /LMDZ6/trunk/libf/dyn3d/guide_mod.F90	(revision 5071)
@@ -12,8 +12,8 @@
   USE Write_Field
   USE lmdz_netcdf, ONLY: nf90_nowrite, nf90_open, nf90_inq_varid, nf90_close, &
-          nf90_inq_dimid, nf90_inquire_dimension, nf_put_var_rd, nf90_float, nf90_def_var, &
+          nf90_inq_dimid, nf90_inquire_dimension, nf90_float, nf90_def_var, &
           nf_create, nf_def_dim, nf_open, nf_unlimited, nf_write, nf_enddef, nf_redef, &
-          nf_close, nf_inq_varid, nf_put_vara_rd, nf90_get_var, nf90_noerr, nf_clobber, &
-          nf_64bit_offset, nf_inq_dimid, nf_inq_dimlen
+          nf_close, nf_inq_varid, nf90_get_var, nf90_noerr, nf_clobber, &
+          nf_64bit_offset, nf_inq_dimid, nf_inq_dimlen, nf90_put_var
   USE pres2lev_mod, ONLY: pres2lev
 
@@ -1707,13 +1707,13 @@
 
 ! Enregistrement des variables dimensions
-        ierr = nf_put_var_rd(nid,vid_lonu,rlonu*180./pi)
-        ierr = nf_put_var_rd(nid,vid_lonv,rlonv*180./pi)
-        ierr = nf_put_var_rd(nid,vid_latu,rlatu*180./pi)
-        ierr = nf_put_var_rd(nid,vid_latv,rlatv*180./pi)
-        ierr = nf_put_var_rd(nid,vid_lev,presnivs)
-        ierr = nf_put_var_rd(nid,vid_cu,cu)
-        ierr = nf_put_var_rd(nid,vid_cv,cv)
-        ierr = nf_put_var_rd(nid,vid_au,alpha_u)
-        ierr = nf_put_var_rd(nid,vid_av,alpha_v)
+        ierr = nf90_put_var(nid,vid_lonu,rlonu*180./pi)
+        ierr = nf90_put_var(nid,vid_lonv,rlonv*180./pi)
+        ierr = nf90_put_var(nid,vid_latu,rlatu*180./pi)
+        ierr = nf90_put_var(nid,vid_latv,rlatv*180./pi)
+        ierr = nf90_put_var(nid,vid_lev,presnivs)
+        ierr = nf90_put_var(nid,vid_cu,cu)
+        ierr = nf90_put_var(nid,vid_cv,cv)
+        ierr = nf90_put_var(nid,vid_au,alpha_u)
+        ierr = nf90_put_var(nid,vid_av,alpha_v)
         call nf95_put_var(nid, varid_alpha_t, alpha_t)
         call nf95_put_var(nid, varid_alpha_q, alpha_q)
@@ -1789,5 +1789,5 @@
     END SELECT
 
-    ierr = nf_put_vara_rd(nid,varid,start,count,field2)
+    ierr = nf90_put_var(nid,varid,field2,start,count)
     ierr = NF_CLOSE(nid)
 
Index: /LMDZ6/trunk/libf/dyn3dmem/guide_loc_mod.F90
===================================================================
--- /LMDZ6/trunk/libf/dyn3dmem/guide_loc_mod.F90	(revision 5070)
+++ /LMDZ6/trunk/libf/dyn3dmem/guide_loc_mod.F90	(revision 5071)
@@ -10,7 +10,7 @@
   use lmdz_netcdf, only: nf90_nowrite, nf90_open, nf90_inq_varid, nf90_close, &
           nf90_inq_dimid, nf90_inquire_dimension, nf_get_vara_rd, nf_inq_dimid, &
-          nf_inq_dimlen, nf_enddef, nf_def_dim, nf_put_var_rd, nf_noerr, nf_close, nf_inq_varid, &
+          nf_inq_dimlen, nf_enddef, nf_def_dim, nf90_put_var, nf_noerr, nf_close, nf_inq_varid, &
           nf_redef, nf_write, nf_unlimited, nf_float, nf_clobber, nf_64bit_offset, nf90_float, &
-          nf_create, nf_def_var, nf_open, nf_put_vara_rd
+          nf_create, nf_def_var, nf_open
   USE parallel_lmdz
   USE pres2lev_mod, only: pres2lev
@@ -2257,13 +2257,13 @@
 
 ! Enregistrement des variables dimensions
-        ierr = nf_put_var_rd(nid,vid_lonu,rlonu*180./pi)
-        ierr = nf_put_var_rd(nid,vid_lonv,rlonv*180./pi)
-        ierr = nf_put_var_rd(nid,vid_latu,rlatu*180./pi)
-        ierr = nf_put_var_rd(nid,vid_latv,rlatv*180./pi)
-        ierr = nf_put_var_rd(nid,vid_lev,presnivs)
-        ierr = nf_put_var_rd(nid,vid_cu,cu)
-        ierr = nf_put_var_rd(nid,vid_cv,cv)
-        ierr = nf_put_var_rd(nid,vid_au,zu)
-        ierr = nf_put_var_rd(nid,vid_av,zv)
+        ierr = nf90_put_var(nid,vid_lonu,rlonu*180./pi)
+        ierr = nf90_put_var(nid,vid_lonv,rlonv*180./pi)
+        ierr = nf90_put_var(nid,vid_latu,rlatu*180./pi)
+        ierr = nf90_put_var(nid,vid_latv,rlatv*180./pi)
+        ierr = nf90_put_var(nid,vid_lev,presnivs)
+        ierr = nf90_put_var(nid,vid_cu,cu)
+        ierr = nf90_put_var(nid,vid_cv,cv)
+        ierr = nf90_put_var(nid,vid_au,zu)
+        ierr = nf90_put_var(nid,vid_av,zv)
         call nf95_put_var(nid, varid_alpha_t, zt)
         call nf95_put_var(nid, varid_alpha_q, zq)
@@ -2355,5 +2355,5 @@
 !$OMP MASTER
 
-    ierr = nf_put_vara_rd(nid,varid,start,count,field_glo)
+    ierr = nf90_put_var(nid,varid,field_glo,start,count)
     ierr = NF_CLOSE(nid)
 
Index: /LMDZ6/trunk/libf/misc/lmdz_netcdf.F90
===================================================================
--- /LMDZ6/trunk/libf/misc/lmdz_netcdf.F90	(revision 5070)
+++ /LMDZ6/trunk/libf/misc/lmdz_netcdf.F90	(revision 5071)
@@ -30,44 +30,3 @@
 CONTAINS
 
-  ! Note: below, we use the same declarations as the fortran netcdf lib, hence the use of (*)
-
-  ! We'd like to use "nf_put_var", but it already exists as a legacy nc4 function
-  ! CPP_NC_DOUBLE wrapper around nf_put_var_real, nf_put_var_double
-  INTEGER FUNCTION nf_put_var_rd(ncid, varid, vals)
-    INTEGER, INTENT(IN) :: ncid, varid
-    REAl(REAL_FORMAT), INTENT(IN) :: vals(*)  ! (*) as declared in netcdf lib
-
-    IF (CPP_NC_DOUBLE) THEN
-      nf_put_var_rd = nf_put_var_double(ncid, varid, vals)
-    ELSE
-      nf_put_var_rd = nf_put_var_real(ncid, varid, vals)
-    END IF
-  END FUNCTION nf_put_var_rd
-
-  ! CPP_NC_DOUBLE wrapper around nf_put_vara_real, nf_put_vara_double
-  INTEGER FUNCTION nf_put_vara_rd(ncid, varid, start, counts, vals)
-    INTEGER, INTENT(IN) :: ncid, varid
-    INTEGER, INTENT(IN) :: start(*), counts(*)
-    REAl(REAL_FORMAT), INTENT(IN) :: vals(*)
-
-    IF (CPP_NC_DOUBLE) THEN
-      nf_put_vara_rd = nf_put_vara_double(ncid, varid, start, counts, vals)
-    ELSE
-      nf_put_vara_rd = nf_put_vara_real(ncid, varid, start, counts, vals)
-    END IF
-  END FUNCTION nf_put_vara_rd
-
-  ! CPP_NC_DOUBLE wrapper around nf_get_vara_real, nf_get_vara_double
-  INTEGER FUNCTION nf_get_vara_rd(ncid, varid, start, counts, vals)
-    INTEGER, INTENT(IN) :: ncid, varid
-    INTEGER, INTENT(IN) :: start(*), counts(*)
-    REAl(REAL_FORMAT), INTENT(OUT) :: vals(*)
-
-    IF (CPP_NC_DOUBLE) THEN
-      nf_get_vara_rd = nf_get_vara_double(ncid, varid, start, counts, vals)
-    ELSE
-      nf_get_vara_rd = nf_get_vara_real(ncid, varid, start, counts, vals)
-    END IF
-  END FUNCTION nf_get_vara_rd
-
 END MODULE lmdz_netcdf
