Build debug version of Boost on CentOS 7

99封情书 提交于 2021-02-11 05:29:22

问题


I'm trying to build a debug version of Boost on CentOS 7 with the following command:

./b2 runtime-link=shared runtime-debugging=on variant=debug link=shared install

However, I don't see the g nor d ABI flag in the names of the generated library files. Have I done something wrong? Everything works just fine when building on Windows.


回答1:


I think that should work.

If building like you do and inspecting one of the resulting libs with objdump

objdump --syms libboost_wave.so | grep debug

I get

...
0000000000000000 l    d  .debug_aranges 0000000000000000              .debug_aranges
0000000000000000 l    d  .debug_info    0000000000000000              .debug_info
0000000000000000 l    d  .debug_abbrev  0000000000000000              .debug_abbrev
0000000000000000 l    d  .debug_line    0000000000000000              .debug_line
0000000000000000 l    d  .debug_str     0000000000000000              .debug_str
0000000000000000 l    d  .debug_ranges  0000000000000000              .debug_ranges
...

If building without "runtime-debugging=on variant=debug" the corresponding result do not result in any matches for "grep debug".



来源:https://stackoverflow.com/questions/33497658/build-debug-version-of-boost-on-centos-7

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!