So I'm building a bunch of modules with g++. I hit some of the source files with -c to produce the .o object files. I then at some points combine object files using the -r flag for ld to produce even more .o files. Somewhere in the process, a function is not getting included. So what I'm trying to do is find a quick tool that looks at a .o file and tells what references are currently undefined.
Asked
Active
Viewed 5,162 times
2 Answers
7
Try the nm
command on Linux/Unix. In the output, "U" means the symbol is undefined.
Also see: Difference between nm and objdump.