shared libraries
Andres Gonzalez
gonzo at agoralabs.com
Mon Mar 10 17:17:55 MDT 2008
I am building a shared library and have a general question about
symbols in a shared library.
I am using the utility nm to show the symbols in the shared library
.so file. When I compile the .so, I have specified the visibility so
that only the API functions that I want exposed are exported. So,
when I then uses nm -g it will only list the exported API functions.
My question is about the utility "strip" If I use strip on the
shared library, then nm reports that there are no symbols in the .so
library. But I can still use the stripped library and link to it.
How is this so? If strip removes the symbols, how can you then link
other code to it?
For a shared library that I am going to release to a customer, should
I use strip to remove the symbols?
If I use strip to remove the symbols, does that restrict the use of
the shared library in any way?
Thanks,
-Andres
More information about the PLUG
mailing list