sorry for the disturbing.
Now I compile all my ocean model with the help of ifort, but I also need to use the NCL static lib which compiled by gfortran. it always said that "undefined reference to MAIN__"
What should I do now? Thanks for your help.
You can't do this - it won't work. In general, you must recompile all sources using a single Fortran compiler. Objects and libraries from one Fortran compiler don't work with those from another.