rosmake dont know std ?
Hi everyone, I got an issue compiling my node with rosmake. it didn't find std :
error: ‘to_string’ is not a member of ‘std’
Did I miss something ?
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
to_string()
is a C++11
feature (see here). Thus, you need to configure the CMakeLists.txt
accordingly.
Also, you should consider switching to catkin
;-)
For catkin
and with CMake >= 2.8.12
and a suitable g++ version (from Ubuntu 14.04 onward? I'm not quite sure) best use:
target_compile_options(<TARGET> PRIVATE -std=c++11)
Asked: 2016-03-11 08:17:01 -0500
Seen: 678 times
Last updated: Mar 11 '16