[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[netCDF #JJC-982930]: error building Fortran netCDF on Mac OS X 10.8.2



Hi Marko,

Sorry to have taken so long to respond to your question ...
> I'm trying to build the netCDF Fortran libraries on Mac OS X Version 10.8.2.
> 
> I've successfully installed the C libraries but when I test the Fortran
> library I get the following error message. I am using gfortran 4.5. Any
> help is much appreciated.

The error message indicates "__gfortran_set_options" is not found, and that's
supposed to be supplied by the Fortran runtime library, not netCDF.  I think
you are seeing a problem with incompatibility between your gfortran and the 
gcc that comes with XTools.  I recommend you use a gfortran that has been built
to work with the OSX gcc that comes with XTools for OSX 10.8, for example from 
here:

  http://hpc.sourceforge.net/

--Russ

> ----------------
> 
> address@hidden ~/Downloads/netcdf-fortran-4.2% make check
> Making check in f90
> make  check-am
> make[2]: Nothing to be done for `check-am'.
> Making check in fortran
> make  check-am
> make[2]: Nothing to be done for `check-am'.
> Making check in nf_test
> make  nf_test tst_f77_v2 ftst_vars ftst_vars2 ftst_vars3 ftst_vars4
> ftst_vars5 ftst_vars6 ftst_types ftst_types2 ftst_types3 ftst_groups
> f90tst_vars tst_types tst_types2 f90tst_vars_vlen tst_f90_nc4
> f90tst_grps f90tst_fill f90tst_fill2 f90tst_vars3 f90tst_vars4
> f90tst_vars2 ftst_v2     ftest tst_f90
> /bin/sh ../libtool --tag=F77   --mode=link gfortran -I../fortran
> -I../f90 -g -O2   -o nf_test test_get.o test_put.o nf_error.o nf_test.o
> test_read.o test_write.o util.o fortlib.o ../fortran/libnetcdff.la
> -lnetcdf
> libtool: link: gfortran -I../fortran -I../f90 -g -O2 -o .libs/nf_test
> test_get.o test_put.o nf_error.o nf_test.o test_read.o test_write.o
> util.o fortlib.o  ../fortran/.libs/libnetcdff.dylib -L/usr/local/lib
> /usr/local/lib/libnetcdf.dylib -lm -lz -lcurl
> Undefined symbols for architecture x86_64:
> "__gfortran_set_options", referenced from:
> _main in nf_test.o
> ld: symbol(s) not found for architecture x86_64
> collect2: ld returned 1 exit status
> make[2]: *** [nf_test] Error 1
> make[1]: *** [check-am] Error 2
> make: *** [check-recursive] Error 1
> 
> --
> Dr. Marko Scholze
> Senior Lecturer
> Department of Physical Geography and Ecosystem Science
> Lund University, SÃlvegatan 12, SE-223 62 Lund
> Phone:+46 46 222 4082
> www.nateko.lu.se
> 
> 
Russ Rew                                         UCAR Unidata Program
address@hidden                      http://www.unidata.ucar.edu



Ticket Details
===================
Ticket ID: JJC-982930
Department: Support netCDF
Priority: Normal
Status: Closed


NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly available through the web. If you do not want to have your interactions made available in this way, you must let us know in each email you send to us.