Ask Your Question

Nodes running from eclipse in debug not in rosnode list [closed]

asked 2015-05-13 02:41:30 -0500

Reiner gravatar image

updated 2015-06-25 01:23:17 -0500

I'm running a ROS-node from eclipse (catkin Project) in debug mode (-g for GCC) and when debugging them (brakepoint pretty much in the middle of the node), after calling ros::init (registering the node) it does not pop up in the node list (rosnode list) but the node is able to use ROS_INFO() and prints the proper ros timecode next to the prints.

Due to the size of the project i desperately need debugging and this is the only option that allows me to debug threw my node code and also step into the source for my lib. i realize there is a much cleaner way to switch btw. debug and release, this was the fastest one (working on it).

My CMakeLists.txt for the package:

cmake_minimum_required(VERSION 2.8.3)
find_package(catkin REQUIRED COMPONENTS roscpp rospy std_msgs )
catkin_package( INCLUDE_DIRS include LIBRARIES mylib
CATKIN_DEPENDS roscpp rospy std_msgs message_runtime)

SET(CMAKE_BUILD_TYPE distribution)

${catkin_INCLUDE_DIRS} include src )
add_executable(test_service_server src/test_service_server.cpp)
target against target_link_libraries( test_service_server ${catkin_LIBRARIES} ${PROJECT_SOURCE_DIR}/lib/

Is there a reason for it (ROS not registering nodes compiled as debug code etc.) or did i somehow manage do screw sth. up?

Edit: this seems to be the same problem.

Edit2: @Dirk Thomas proposed a solve:


it seems to be, what I need. Question answered.

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Reiner
close date 2015-06-25 01:23:40.679982


ROS nodes will behave the same when being built in debug mode as in release mode. Except that they have more debug output. might be slower and provide line information when being run in a debugger.

Dirk Thomas gravatar image Dirk Thomas  ( 2015-06-24 11:40:53 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2015-06-24 11:39:40 -0500

Dirk Thomas gravatar image

You should use the Debug build type already defined in CMake instead of a custom and likely incomplete build type:

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2015-05-13 02:41:30 -0500

Seen: 146 times

Last updated: Jun 25 '15