Opened 10 years ago

Last modified 10 years ago

#42414 closed defect

netcdf-fortran @4.2_11 dyld failure — at Version 2

Reported by: jsalort (Julien Salort) Owned by: takeshi@…
Priority: Normal Milestone:
Component: ports Version: 2.2.1
Keywords: Cc:
Port: netcdf-fortran

Description (last modified by ryandesign (Ryan Carsten Schmidt))

A simple f90 file calling nf90_create results in the following error:

dyld: lazy symbol binding failed: Symbol not found: _nf_create_
  Referenced from: /opt/local/lib/libnetcdff.5.dylib
  Expected in: flat namespace

dyld: Symbol not found: _nf_create_
  Referenced from: /opt/local/lib/libnetcdff.5.dylib
  Expected in: flat namespace


Program received signal SIGTRAP: Trace/breakpoint trap.

Backtrace for this error:
#0  0x10e40de7d
#1  0x10e40e38b
#2  0x7fff85ab0909
Trace/BPT trap: 5

The file was compiled with the command:

`nc-config --fc` `nc-config --fflags` -o essai essai.f90 `nc-config --flibs`

The result of nc-config appears to be ok:

$ nc-config --fc
/opt/local/bin/gfortran-mp-4.8
$ nc-config --fflags
-pipe -Os -I/opt/local/include
$ nc-config --flibs
-L/opt/local/lib -lnetcdff -L/opt/local/lib -Wl,-headerpad_max_install_names -lnetcdf -lnetcdf

I have tried several gcc variants (gcc44, gcc46 and gcc48) but I get the same result each time on Mountain Lion with MacPorts 2.2.1. The same versions on Mavericks appears to work. Enclosed is an example simple source file grabbed from netcdf website, which reproduces the problem.

Change History (3)

Changed 10 years ago by jsalort (Julien Salort)

Attachment: essai.f90 added

Example source file

comment:1 in reply to:  description Changed 10 years ago by jsalort (Julien Salort)

The same versions on Mavericks appears to work.

Actually, there is the same problem on Mavericks after all. I thought it worked because I had netcdf-fortran @4.2_10. After updating to @4.2_11, I get the same problem on both Mavericks and Mountain Lion.

comment:2 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Owner: changed from macports-tickets@… to takeshi@…
Port: netcdf-fortran added
Note: See TracTickets for help on using tickets.