Find out what functions a static C library has
35,805
Solution 1
On Windows you can use dumpbin
. On Linux and friends you can use nm
.
Solution 2
Use nm. That will only give you the symbol names - of which most of the symbols prefixed with T
will be functions. Function arguments are not retained in the binary.
Author by
cd1
Updated on October 05, 2020Comments
-
cd1 over 3 years
I have a static C library (say
mylib.a
) and I was wondering if it's possible to find out what functions are implemented inside that file. I don't have a corresponding header file. what I need is like the equivalent ofjavap
for Java. -
Kemin Zhou over 7 yearsnm works with both dynamic (libfoo.so) and static (libbar.a) libraries