Symbols in header files C/C++ -
how find symbols being referenced in header-file source files?
want find out programmatically.
the brute force method:
- in source file, comment out inclusion of header file.
- recompile source file.
the compiler should emit list of undefined symbols.
you may need apply recursively if header file includes other files.
edit 1: map files
compiler may able generate cross reference listing of symbols , used. specific each compiler. consult compiler's documentation.
also check linker's documentation well.
the compiler can generate map file shows symbols, values , locations. may show symobls used, not in header files.
Comments
Post a Comment