plotgrids and plotfmt won't compile on Mac OSX

Installing the WRF Preprocessing System

plotgrids and plotfmt won't compile on Mac OSX

Postby jared-lee » Tue Jul 12, 2011 5:04 pm

Hi, I'm trying to install WPS 3.3 on a 64-bit Intel Mac (OS 10.6.8). Unfortunately I can't figure out how to get plotgrids or plotfmt to compile. I've had trouble getting these two programs to compile on other platforms previously, but I haven't seen these errors before. I'll ultimately need GRIB2 support, but for now I'm just trying to get the installation to work without GRIB2 support to keep things simpler.

Here's what I'm using:
--gfortran with gcc 4.2.1.
--NetCDF 4.1.1
--NCL/NCARG 6.0.0

Below are various snips from the compile.log file. Can anyone give me some suggestions about what's wrong? I should add that even though the first two error messages claim that the files ungrib/src/ngl/w3/libw3.a and ungrib/src/ngl/g2/libg2_4.a don't exist, they are created during compilation.

Jared

......

ar: creating archive libw3.a
ranlib libw3.a
ranlib: can't open file: w3/libw3.a (No such file or directory)
make[1]: [w3/libw3.a] Error 1 (ignored)
ln -sf w3/libw3.a .

......

ar: creating archive libg2_4.a
ranlib libg2_4.a
ranlib: can't open file: g2/libg2_4.a (No such file or directory)
make[1]: [g2/libg2_4.a] Error 1 (ignored)
ln -sf g2/libg2_4.a .

......

gfortran -ffree-form -O -fconvert=big-endian -frecord-marker=4 -c plotfmt.f90
gfortran -o plotfmt.exe plotfmt.o read_met_module.o module_debug.o \
misc_definitions_module.o cio.o met_data_module.o \
-L/usr/local/ncarg6/lib -lncarg -lncarg_gks -lncarg_c -L/usr/X11R6/lib -lXpm -lX11 -lXext -L/usr/lib -L/usr/local/lib -lgfortran -lpng12 -lpng
Undefined symbols:
"__gfortran_os_error", referenced from:
_dpgetr_ in libncarg.a(dpgetr.o)
_dpgetr_ in libncarg.a(dpgetr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_icfell_ in libncarg.a(icfell.o)
_icfell_ in libncarg.a(icfell.o)
_dpsetc_ in libncarg.a(dpsetc.o)
_dpsetc_ in libncarg.a(dpsetc.o)
_dpsetr_ in libncarg.a(dpsetr.o)
_dpsetr_ in libncarg.a(dpsetr.o)
_dpgetc_ in libncarg.a(dpgetc.o)
_dpgetc_ in libncarg.a(dpgetc.o)
_pcfopn_ in libncarg.a(pcfopn.o)
_mdpcem_ in libncarg.a(mdpcem.o)
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[1]: [plotfmt.exe] Error 1 (ignored)

......

gfortran -ffree-form -O -fconvert=big-endian -frecord-marker=4 -c plotgrids.f90
gfortran -o plotgrids.exe module_map_utils.o module_debug.o cio.o constants_module.o misc_definitions_module.o \
plotgrids.o -L/usr/local/ncarg6/lib -lncarg -lncarg_gks -lncarg_c -L/usr/X11R6/lib -lXpm -lX11 -lXext -L/usr/lib -L/usr/local/lib -lgfortran -lpng12 -lpng
Undefined symbols:
"__gfortran_os_error", referenced from:
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_mdlndr_ in libncarg.a(mdlndr.o)
_icfell_ in libncarg.a(icfell.o)
_icfell_ in libncarg.a(icfell.o)
_pcfopn_ in libncarg.a(pcfopn.o)
_mdpcem_ in libncarg.a(mdpcem.o)
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[1]: [plotgrids.exe] Error 1 (ignored)

jared-lee
 
Posts: 25
Joined: Wed Jun 09, 2010 7:20 pm

Re: plotgrids and plotfmt won't compile on Mac OSX

Postby jared-lee » Wed Jul 13, 2011 5:27 pm

On a whim I decided to install pgi-compiled versions of NetCDF (3.6.3) and NCAR Graphics (6.0.0), to see if that might solve the errors I detailed above. It did, and now plotgrids and plotfmt both compile. I also tried a pgi install of NetCDF (4.1.3), but that failed with the above WPS errors plus others (geogrid and metgrid wouldn't compile because of problems with libnetcdf.a).

So I don't know yet whether the problem lies with gnu-compiled NetCDF or NetCDF 4.x (or both), but it appears the problem is with one of those. At any rate, it all works for me with pgi-compiled NetCDF 3.6.3.

Jared
jared-lee
 
Posts: 25
Joined: Wed Jun 09, 2010 7:20 pm


Return to Installation

Who is online

Users browsing this forum: No registered users and 2 guests