SICKAG / sick_ldmrs_laser

A ROS driver for the SICK LD-MRS series of laser scanners.
BSD 3-Clause "New" or "Revised" License
24 stars 19 forks source link

Compile error on ARM tegra K1 board #5

Closed prango closed 7 years ago

prango commented 7 years ago

Its giving error on compling with catkinmake_isolate and throwing our this output on ARM tegra K1 baord , Distributor ID: Ubuntu Description: Ubuntu 14.04.1 LTS Release: 14.04 Codename: trusty ROS indigo

<== Finished processing package [24 of 246]: 'laser_pipeline'

==> Processing plain cmake package: 'libsick_ldmrs' ==> Building with env: '/home/ubuntu/ros_catkin_ws/install_isolated/env.sh' ==> cmake /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs -DCMAKE_INSTALL_PREFIX=/home/ubuntu/ros_catkin_ws/install_isolated -DCMAKE_BUILD_TYPE=Release -G Unix Makefiles in '/home/ubuntu/ros_catkin_ws/build_isolated/libsick_ldmrs/install' -- Configuring done -- Generating done -- Build files have been written to: /home/ubuntu/ros_catkin_ws/build_isolated/libsick_ldmrs/install ==> make -j4 -l4 in '/home/ubuntu/ros_catkin_ws/build_isolated/libsick_ldmrs/install' Scanning dependencies of target LDMRS_Example Scanning dependencies of target sick_ldmrs [ 1%] [ 2%] [ 3%] Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/toolbox.cpp.o Building CXX object src/CMakeFiles/LDMRS_Example.dir/main.cpp.o Building CXX object src/CMakeFiles/sick_ldmrs.dir/tools/toolbox.cpp.o /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp: In function 'std::string toString(size_t)': /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:288:13: error: redefinition of 'std::string toString(size_t)' std::string toString(size_t value) ^ /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:281:13: error: 'std::string toString(UINT32)' previously defined here std::string toString(UINT32 value) ^ /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp: In function 'std::string toString(size_t)': /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:288:13: error: redefinition of 'std::string toString(size_t)' std::string toString(size_t value) ^ /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:281:13: error: 'std::string toString(UINT32)' previously defined here std::string toString(UINT32 value) ^ make[2]: [src/CMakeFiles/LDMRS_Example.dir/tools/toolbox.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... make[2]: [src/CMakeFiles/sick_ldmrs.dir/tools/toolbox.cpp.o] Error 1 make[1]: [src/CMakeFiles/sick_ldmrs.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... make[1]: [src/CMakeFiles/LDMRS_Example.dir/all] Error 2 make: *** [all] Error 2 <== Failed to process package 'libsick_ldmrs': Command '['/home/ubuntu/ros_catkin_ws/install_isolated/env.sh', 'make', '-j4', '-l4']' returned non-zero exit status 2

Reproduce this error by running: ==> cd /home/ubuntu/ros_catkin_ws/build_isolated/libsick_ldmrs && /home/ubuntu/ros_catkin_ws/install_isolated/env.sh make -j4 -l4

Command failed, exiting.

jspricke commented 7 years ago

@prango I've pushed a fix here: https://github.com/SICKAG/libsick_ldmrs/pull/2, can you try it?

prango commented 7 years ago

@jspricke Yes. I will try it now and let you know

prango commented 7 years ago

Still giving the same err. I removed the previous build and pulled from the source again.

[ 81%] Building CXX object src/CMakeFiles/sick_ldmrs.dir/tools/Mutex.cpp.o [ 82%] Building CXX object src/CMakeFiles/sick_ldmrs.dir/tools/toolbox.cpp.o [ 83%] [ 84%] Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/errorhandler.cpp.o Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/SickThread.cpp.o [ 85%] Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/Mutex.cpp.o [ 86%] [ 87%] [ 88%] Building CXX object src/CMakeFiles/sick_ldmrs.dir/tools/MathToolbox.cpp.o Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/toolbox.cpp.o Building CXX object src/CMakeFiles/sick_ldmrs.dir/tools/BasicDataBuffer.cpp.o /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp: In function 'std::string toString(size_t)': /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:288:13: error: redefinition of 'std::string toString(size_t)' std::string toString(size_t value) ^ /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:281:13: error: 'std::string toString(UINT32)' previously defined here std::string toString(UINT32 value) ^ make[2]: [src/CMakeFiles/sick_ldmrs.dir/tools/toolbox.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... [ 89%] Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/MathToolbox.cpp.o make[1]: [src/CMakeFiles/sick_ldmrs.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... [ 90%] Building CXX object src/CMakeFiles/LDMRS_Example.dir/tools/Timer.cpp.o /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp: In function 'std::string toString(size_t)': /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:288:13: error: redefinition of 'std::string toString(size_t)' std::string toString(size_t value) ^ /home/ubuntu/ros_catkin_ws/src/libsick_ldmrs/src/tools/toolbox.cpp:281:13: error: 'std::string toString(UINT32)' previously defined here std::string toString(UINT32 value) ^ make[2]: [src/CMakeFiles/LDMRS_Example.dir/tools/toolbox.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... make[1]: [src/CMakeFiles/LDMRS_Example.dir/all] Error 2 make: [all] Error 2 make: INTERNAL: Exiting with 5 jobserver tokens available; should be 4! <== Failed to process package 'libsick_ldmrs': Command '['/home/ubuntu/ros_catkin_ws/install_isolated/env.sh', 'make', '-j4', '-l4']' returned non-zero exit status 2

Reproduce this error by running: ==> cd /home/ubuntu/ros_catkin_ws/build_isolated/libsick_ldmrs && /home/ubuntu/ros_catkin_ws/install_isolated/env.sh make -j4 -l4

Command failed, exiting.

jspricke commented 7 years ago

Did you include my patch, as linked above?

prango commented 7 years ago

Its compiling now ! Thanks !! yes i forgot to include the patch in the previous build. I thought you pushed in the master branch.

i'll let you know if any other error pops up. :) @jspricke @mintar thanks for the quick reply.

jspricke commented 7 years ago

Sounds like you are trying to compile all of ROS. I would propose to install it through apt, see http://wiki.ros.org/indigo/Installation/UbuntuARM

prango commented 7 years ago

@jspricke I actually have the ROS installed in the system. I am just follwing the https://github.com/SICKAG/sick_ldmrs_laser#from-source which leads me to the error.

Sorry to ping you again but I cannot figure what am I doing wrong.

jspricke commented 7 years ago

but that shouldn't get all of ROS (like qt_gui_py_common or actionlib_msgs) into your catkin workspace. Can you start with a fresh catkin_ws/src with only libsick_ldmrs and sick_ldmrs_laser included?

prango commented 7 years ago

@jspricke I'll try to do that.

prango commented 7 years ago

I made a fresh catkin space and compiled on the lidar packeges. At the end of the compilation its showing

==> Processing catkin package: 'sick_ldmrs_tools' ==> Building with env: '/home/ubuntu/catkin_lidar_ws/install_isolated/env.sh' Makefile exists, skipping explicit cmake invocation... ==> make cmake_check_build_system in '/home/ubuntu/catkin_lidar_ws/build_isolated/sick_ldmrs_tools' ==> make -j4 -l4 in '/home/ubuntu/catkin_lidar_ws/build_isolated/sick_ldmrs_tools' [ 0%] [ 0%] [ 0%] [ 0%] Built target sick_ldmrs_msgs_generate_messages_lisp Built target roscpp_generate_messages_cpp Built target sick_ldmrs_msgs_generate_messages_cpp Built target tf2_msgs_generate_messages_lisp [ 0%] [ 0%] [ 0%] Built target pcl_ros_gencfg [ 0%] Built target dynamic_reconfigure_generate_messages_lisp Built target visualization_msgs_generate_messages_cpp Built target roscpp_generate_messages_py [ 0%] [ 0%] [ 0%] [ 0%] Built target nodelet_generate_messages_lisp Built target dynamic_reconfigure_generate_messages_py Built target topic_tools_generate_messages_lisp Built target dynamic_reconfigure_gencfg [ 0%] [ 0%] Built target nodelet_generate_messages_cpp Built target sensor_msgs_generate_messages_lisp [ 0%] Built target nodelet_generate_messages_py [ 0%] Built target sick_ldmrs_msgs_generate_messages_py [ 0%] Built target rosgraph_msgs_generate_messages_py [ 0%] [ 0%] Built target geometry_msgs_generate_messages_py [ 0%] Built target visualization_msgs_generate_messages_py Built target visualization_msgs_generate_messages_lisp [ 0%] [ 0%] [ 0%] Built target bond_generate_messages_cpp Built target tf_generate_messages_lisp Built target roscpp_generate_messages_lisp [ 0%] Built target bond_generate_messages_lisp [ 0%] [ 0%] Built target bond_generate_messages_py Built target pcl_msgs_generate_messages_lisp [ 0%] [ 0%] Built target dynamic_reconfigure_generate_messages_cpp Built target pcl_msgs_generate_messages_py [ 0%] [ 0%] [ 0%] Built target std_msgs_generate_messages_cpp Built target geometry_msgs_generate_messages_cpp Built target std_msgs_generate_messages_py [ 0%] Built target std_msgs_generate_messages_lisp [ 0%] [ 0%] Built target rosgraph_msgs_generate_messages_cpp Built target rosgraph_msgs_generate_messages_lisp [ 0%] Built target geometry_msgs_generate_messages_lisp [ 0%] Built target tf_generate_messages_py [ 0%] [ 0%] Built target topic_tools_generate_messages_cpp Built target pcl_msgs_generate_messages_cpp [ 0%] [ 0%] Built target sensor_msgs_generate_messages_cpp Built target sensor_msgs_generate_messages_py [ 0%] [ 0%] Built target tf_generate_messages_cpp Built target topic_tools_generate_messages_py [ 0%] [ 0%] Built target actionlib_generate_messages_cpp Built target actionlib_generate_messages_lisp [ 0%] [ 0%] [ 0%] Built target actionlib_msgs_generate_messages_lisp Built target actionlib_msgs_generate_messages_cpp Built target actionlib_msgs_generate_messages_py [ 0%] Built target actionlib_generate_messages_py [ 0%] Built target tf2_msgs_generate_messages_py [ 0%] Built target tf2_msgs_generate_messages_cpp [ 12%] [ 25%] [ 37%] [ 50%] Built target sick_ldmrs_filter_first Built target sick_ldmrs_filter_last Building CXX object CMakeFiles/sick_ldmrs_filter_layer.dir/src/sick_ldmrs_filter_layer.cpp.o Building CXX object CMakeFiles/sick_ldmrs_all_layer_assembler.dir/src/sick_ldmrs_all_layer_assembler.cpp.o [ 62%] Built target sick_ldmrs_object_marker [ 75%] Built target sick_ldmrs_make_organized Scanning dependencies of target sick_ldmrs_remove_background [ 87%] Building CXX object CMakeFiles/sick_ldmrs_print_resolution.dir/src/sick_ldmrs_print_resolution.cpp.o [100%] Building CXX object CMakeFiles/sick_ldmrs_remove_background.dir/src/sick_ldmrs_remove_background.cpp.o c++: internal compiler error: Killed (program cc1plus) Please submit a full bug report, with preprocessed source if appropriate. See file:///usr/share/doc/gcc-4.8/README.Bugs for instructions. make[2]: [CMakeFiles/sick_ldmrs_filter_layer.dir/src/sick_ldmrs_filter_layer.cpp.o] Error 4 make[1]: [CMakeFiles/sick_ldmrs_filter_layer.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... c++: internal compiler error: Killed (program cc1plus) Please submit a full bug report, with preprocessed source if appropriate. See file:///usr/share/doc/gcc-4.8/README.Bugs for instructions. make[2]: [CMakeFiles/sick_ldmrs_print_resolution.dir/src/sick_ldmrs_print_resolution.cpp.o] Error 4 make[1]: [CMakeFiles/sick_ldmrs_print_resolution.dir/all] Error 2 Linking CXX executable /home/ubuntu/catkin_lidar_ws/devel_isolated/sick_ldmrs_tools/lib/sick_ldmrs_tools/sick_ldmrs_remove_background [100%] Built target sick_ldmrs_remove_background Linking CXX executable /home/ubuntu/catkin_lidar_ws/devel_isolated/sick_ldmrs_tools/lib/sick_ldmrs_tools/sick_ldmrs_all_layer_assembler [100%] Built target sick_ldmrs_all_layer_assembler make: [all] Error 2 <== Failed to process package 'sick_ldmrs_tools': Command '['/home/ubuntu/catkin_lidar_ws/install_isolated/env.sh', 'make', '-j4', '-l4']' returned non-zero exit status 2

Reproduce this error by running: ==> cd /home/ubuntu/catkin_lidar_ws/build_isolated/sick_ldmrs_tools && /home/ubuntu/catkin_lidar_ws/install_isolated/env.sh make -j4 -l4

Command failed, exiting.

jspricke commented 7 years ago

probably you are running out of memory, try catkin_make_isolated -j1

prango commented 7 years ago

thanks ! it compiled.

after instalation i am running the quick start cmd but its not detecting the pakage files.

ubuntu@tegra-ubuntu:~/catkin_lidar_ws$ roslaunch sick_ldmrs_tools sick_ldmrs_demo.launch [sick_ldmrs_demo.launch] is neither a launch file in package [sick_ldmrs_tools] nor is [sick_ldmrs_tools] a launch file name The traceback for the exception was written to the log file

jspricke commented 7 years ago

continue with the Readme at: catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release

prango commented 7 years ago

I did. I ran the cmd in this order

1.) catkin_make_isolated -j1 2.) source ~/catkin_lidar_ws/install_isolated/setup.bash

(source ~/ros_catkin_ws/install_isolated/setup.bash changed ros_catkin_ws to my catkin space)

If i run catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release again it shows the out of memory error.

jspricke commented 7 years ago

You are missing the catkin_make_isolated --install (i.e. the software is not installed)

prango commented 7 years ago

If i run with catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release it shows the memory error again .

i tried with catkin_make_isolated --install -j1 and it worked.

Thanks a lot for helping me out. @jspricke