linking problem with gfortran 4.2.0
Tim Prince
timothyprince@sbcglobal.net
Fri Jun 9 13:04:00 GMT 2006
Harry Powell wrote:
> Hi
>
> Note that the _only_ difference in my two builds is the compiler. All
> libraries, flags, etc are identical (so it may just mean that I need to
> add another library - but which one?).
>
> I have been trying to build my code on an Intel iMac - with gfortran 4.0.3
> compilation & linking goes okay and the executable is usable (though there
> are some unwanted features introduced by small bugs in the compiler, which
> I believe may have been addressed in newer versions). With gfortran 4.2.0
> I get the following error on linking (in both cases I use the command
> "gfortran" for the linking, but this seems to explicitly invoke odcctools
> in 4.2.0);
>
> /sw/lib/odcctools/bin/ld: Undefined symbols:
> __gfortran_filename
> __gfortran_ioparm
> __gfortran_line
> collect2: ld returned 1 exit status
You must link against the gfortran 4.2 libraries when you compile with
4.2. In my limited experience, objects involving run time library calls
don't mix between 4.0, 4.1, and 4.2.
More information about the Gcc-help
mailing list