Index: /BOL/script_install/install_lmdz.sh
===================================================================
--- /BOL/script_install/install_lmdz.sh	(revision 4237)
+++ /BOL/script_install/install_lmdz.sh	(revision 4238)
@@ -663,4 +663,27 @@
 fi
 
+cat >test_netcdf90.f90 <<EOF
+use netcdf, only: nf90_inq_libvers
+print *, "NetCDF library version: ", nf90_inq_libvers()
+end
+EOF
+
+$compiler -I$ncdfdir/include test_netcdf90.f90 -L$ncdfdir/lib -l netcdff \
+	  -lnetcdf && ./a.out
+    
+if (($? == 0))
+then
+    rm test_netcdf90.f90 a.out
+else
+    echo "Failed test program using NetCDF-Fortran."
+    echo "You can:"
+    echo "- check that you have NetCDF-Fortran installed in your system"
+    echo "- or specify an installation directory with option -netcdf of" \
+	 "install_lmdz.sh"
+    echo "- or download and compile NetCDF-Fortran with option -netcdf 1 of" \
+	 "install_lmdz.sh"
+    exit 1
+fi
+
 #=========================================================================
 if [[ ! -f $MODEL/modipsl/lib/libioipsl.a ]]
