ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A
Ask Your Question

How to turn on generating the debug info?

asked 2014-05-26 06:39:39 -0500

sd gravatar image

Debug symbols information is missing from my node built from cpp file with catkin_make in hydro. I need it to debug the node with the gdb. How to turn on generating the debug info?

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2014-05-26 07:07:08 -0500

Dirk Thomas gravatar image

If you build the package from source you might want to set the CMAKE_BUILD_TYPE to either Debug or RelWithDebInfo (see ) when invoking cmake:

catkin_make -DCMAKE_BUILD_TYPE=Debug
edit flag offensive delete link more

answered 2014-05-26 06:49:56 -0500

sterlingm gravatar image

updated 2014-05-26 06:55:35 -0500

Add the following to your CMakeLists.txt:

set (CMAKE_CXX_FLAGS "-g")
edit flag offensive delete link more


it worked. thank you.

sd gravatar image sd  ( 2014-05-26 07:06:58 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2014-05-26 06:39:39 -0500

Seen: 1,537 times

Last updated: May 26 '14