ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

CMake optimizing out values in debug mode

asked 2013-11-10 06:38:06 -0500

vhwanger gravatar image

updated 2013-11-18 16:40:43 -0500

tfoote gravatar image

I'm trying to view some simple int variables in GDB, but they're all being marked as "value optimized out". At the top of my CMakeLists.txt file, I have

set(ROS_BUILD_TYPE Debug)

Do I need to set something else?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2013-11-10 20:45:03 -0500

tfoote gravatar image

You need to recompile what the section of code that you are running. And if you're inside a library you need to recompile that library. (What you have noted is correct for rosbuild based packages.)

edit flag offensive delete link more

Comments

This is actually after a make clean and rosmake.

vhwanger gravatar image vhwanger  ( 2013-11-12 09:22:10 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2013-11-10 06:38:06 -0500

Seen: 741 times

Last updated: Nov 10 '13