Question on Valgrind
I've tried using Valgrind to profile using callgrind. To get a symbol table I compile with the -g option and get it working on a simple program that uses no external libraries.. I however have to use it for a bigger project that uses an external library, and I compile it specifying the g option.. and it compiles but when I run kcachegrind on the output.. I can't view the source.. and time spent on each line. Does anyone know if I need to specify somethign else than the -g option for bigger projects?
Thanks in advance,
-g should be enough
1) Make sure you're actually linking against the debug build of the library. If it's installed elsewhere on your system, maybe you're getting the wrong one.
2) Make sure the library isn't getting stripped as some final step of its build process
3) Make sure you are linking dynamically