Wednesday, January 18, 2012

Compiling read_wrf_nc with gfortran

Quick but simple tool for extracting time-series from WRF netcdf output. Does not do any de-stagerring of variables.

gfortran lacks iargc, so compile the following

extern int _gfortran_iargc(void);
int iargc_()
{
return _gfortran_iargc();
}

$ gfortran -c gfortran_iargs.c
$ gfortran gfortran_iargc.o read_wrf_nc.f90 -L$NETCDF/lib -lnetcdf -I/$NETCDF/include -ffree-form -o read_wrf_nc 

No comments:

Post a Comment