Trouble getting dlsym to open shared library
Engelbrecht, George
gengelbrecht@its.bldrdoc.gov
Wed Nov 5 17:50:00 GMT 2014
FX,
That appears to have been the issue. Thanks for that.
Much appreciated,
George
> On Nov 5, 2014, at 10:42 AM, FX <fxcoudert@gmail.com> wrote:
>
> Dear George,
>
>> iri_fortran_main = (iri_fortran_main_type)dlsym(hLib,"_iri_sub_”);
>
> Remove the initial underscore in _iri_sub_, says the dyld man page:
>
>> NOTES
>> The symbol name passed to dlsym() is the name used in C source code. For example to find the
>> address of function foo(), you would pass "foo" as the symbol name. This is unlike the older
>> dyld APIs which required a leading underscore. If you looking up a C++ symbol, you need to
>> use the mangled C++ symbol name.
>
>
> For Fortran, you need the final underscore, but not the initial one.
>
>
> FX
More information about the Fortran
mailing list