add a std_msg Header to my custom msg
Hello everyone,
I am trying to add an Header to my custom msg, but what I run catkin_make install
there is an error.
In my CMakeLists.txt
std_msgs
was declare perfectly.
my .msg file is like that:
std_msgs/Header header
int8 pedal_position
float64 steering_angle
bool pto_state
bool emergency_stop
without the first line it is working perfect. I tried to write only Header header
and it doesn't work too.
I know that I can write by myself these variables but I want to know How to do this like this.
Edit: error message:
[ 0%] Built target std_msgs_generate_messages_cpp
[ 0%] Built target std_msgs_generate_messages_py
[ 0%] Built target std_msgs_generate_messages_nodejs
[ 0%] Built target std_msgs_generate_messages_eus
[ 0%] Built target sensor_msgs_generate_messages_lisp
[ 0%] Built target std_msgs_generate_messages_lisp
The dependencies of the message/service 'send_data/datarx' have changed. Please rerun cmake.
send_data/CMakeFiles/_send_data_generate_messages_check_deps_datarx.dir/build.make:57: recipe for target 'send_data/CMakeFiles/_send_data_generate_messages_check_deps_datarx' failed
make[2]: *** [send_data/CMakeFiles/_send_data_generate_messages_check_deps_datarx] Error 1
CMakeFiles/Makefile2:1714: recipe for target 'send_data/CMakeFiles/_send_data_generate_messages_check_deps_datarx.dir/all' failed
make[1]: *** [send_data/CMakeFiles/_send_data_generate_messages_check_deps_datarx.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 0%] Built target sensor_msgs_generate_messages_nodejs
[ 0%] Built target sensor_msgs_generate_messages_eus
[ 0%] Built target sensor_msgs_generate_messages_cpp
[ 0%] Built target _send_data_generate_messages_check_deps_datatx
[ 0%] Built target sensor_msgs_generate_messages_py
[ 0%] Built target _realsense2_camera_generate_messages_check_deps_Extrinsics
[ 0%] Built target _realsense2_camera_generate_messages_check_deps_IMUInfo
Makefile:140: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make install -j8 -l8" failed
Can you edit your question to show the error please ?
Please show your complete
CMakeLists.txt
. And please delete thebuild
anddevel
folders from your workspace and try rebuilding. Just to make sure there are no corrupt/unexpected files or caches somewhere.