libtool
[Top][All Lists]
Advanced

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

Re: ld.so.1 can't find symbol.


From: Peter Eisentraut
Subject: Re: ld.so.1 can't find symbol.
Date: Thu, 26 Apr 2001 21:42:16 +0200 (CEST)

Christopher Lintz writes:

> Can someone offer direction to this strange problem.  I have built a 4 line 
> function and built it into a shared library using libtool.  I call the 
> library with dlopen() (which is succesful), but when I call dlsym() it can't 
> find the symbol for the function.  However, If i go into the gdb debugger and 
> display the functions (info functions) in the symbol table, my function is 
> there!!!  I can even call the function in gdb (call foo(3) ).

C++ uses name mangling to alter the name of linker symbols to allow for
function overloading.  You could use 'nm' to find the bare symbol name but
it's probably better to wrap your function declarations into extern "C"
blocks to make the symbols predictable across platforms.

-- 
Peter Eisentraut   address@hidden   http://funkturm.homeip.net/~peter




reply via email to

[Prev in Thread] Current Thread [Next in Thread]