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

Debian: source build "‘logError’ was not declared in this scope" (cpp_common)

asked 2018-08-13 14:33:07 -0500

michaeldibono gravatar image

updated 2018-08-13 14:43:48 -0500

gvdhoorn gravatar image

Installing Indigo on Debian 7, error obtained when building catkin workspace using:

sudo ./src/catkin/bin/catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release --install-space /opt/ros/indigo


==> Processing catkin package: 'cpp_common'
==> Building with env: '/opt/ros/indigo/'
Makefile exists, skipping explicit cmake invocation...
==> make cmake_check_build_system in '/root/ros_catkin_ws/build_isolated/cpp_common'
==> make -j8 -l8 in '/root/ros_catkin_ws/build_isolated/cpp_common'
[ 50%] Building CXX object CMakeFiles/cpp_common.dir/src/header.cpp.o
/root/ros_catkin_ws/src/roscpp_core/cpp_common/src/header.cpp: In member function ‘bool ros::Header::parse(uint8_t*, uint32_t, std::string&)’:
/root/ros_catkin_ws/src/roscpp_core/cpp_common/src/header.cpp:82:39: error: ‘logError’ was not declared in this scope
/root/ros_catkin_ws/src/roscpp_core/cpp_common/src/header.cpp:96:39: error: ‘logError’ was not declared in this scope
make[2]: *** [CMakeFiles/cpp_common.dir/src/header.cpp.o] Error 1
make[1]: *** [CMakeFiles/cpp_common.dir/all] Error 2
make: *** [all] Error 2
<== Failed to process package 'cpp_common': 
  Command '['/opt/ros/indigo/', 'make', '-j8', '-l8']' returned non-zero exit status 2

Reproduce this error by running:
==> cd /root/ros_catkin_ws/build_isolated/cpp_common && /opt/ros/indigo/ make -j8 -l8

Command failed, exiting.

What should I do to resolve this issue? Thank you!

edit retag flag offensive close merge delete


any solutions? stuck with the same problem!!

tush gravatar image tush  ( 2018-08-24 09:52:54 -0500 )edit

2 Answers

Sort by » oldest newest most voted

answered 2018-08-25 02:09:03 -0500

halfRobopPrince gravatar image

If you go through the error, it says that logError is not in the scope. This basically means there is no definition of that function.

Based on this: all the log* functions are now appended with CONSOLE_BRIDGE_log* where log* could be logError, logDebug, logWarn, etc.

Thus go to the file which is /root/ros_catkin_ws/src/roscpp_core/cpp_common/src/header.cpp in your case and append CONSOLE_BRIDGE_ to every occurrence of logError function.

  • sudo nano /root/ros_catkin_ws/src/roscpp_core/cpp_common/src/header.cpp
  • Ctrl+w
  • Search logError

Again enter the command for building the workspace. I am pretty sure this error will go but new errors may come. Resolve them in the same way.

That's it!

edit flag offensive delete link more

Question Tools


Asked: 2018-08-13 14:33:07 -0500

Seen: 1,949 times

Last updated: Aug 24 '18