Debugging Symbols Lost When Linking?

前端 未结 2 638
粉色の甜心
粉色の甜心 2021-02-19 01:25

I\'m trying to compile a program with debugging symbols so that valgrind will give me line numbers. I have found that if I compile a simple test program in one go (with -g) then

相关标签:
2条回答
  • 2021-02-19 02:04

    Just for marking this question as "answered" (so it's not needlessly opened and read by others).

    => Answer is found as the comment from "user1288111" to the initial question.

    0 讨论(0)
  • 2021-02-19 02:24

    Final remark - it was indeed an OS X specific 'feature' to do with the way OS X links debug information. Valgrind helps the user circumvent the problem with the command --dsymutil=yes.

    You can read more about it here: http://valgrind.org/docs/manual/manual-core.html#manual-core.erropts

    Credit to Dave Goodell who sent me the solution on valgrind users forum.

    0 讨论(0)
提交回复
热议问题