Repository navigation
micro_ros_agent package failed #303
Copy link
Copy link
Closed
Description
- Installation type: micro_ros_setup
- Version: foxy in Ubuntu 20.04.2
While following the basic tutorials from https://micro.ros.org//docs/tutorials/core/first_application_linux/ all the steps executed fine until I reached the command:ros2 run micro_ros_setup build_agent.sh
Steps to reproduce the issue
After installing ROS2 I followed the "First application Linux" tutorials as it is and the package failure occurred while building micro ros agent.
Expected behavior
The agent should build successfully
Actual behavior
Starting >>> micro_ros_agent
stderr: micro_ros_agent
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `fmt::v6::internal::basic_data<void>::signs'
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `spdlog::logger::log_it_(spdlog::details::log_msg const&, bool, bool)'
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `int fmt::v6::internal::snprintf_float<double>(double, int, fmt::v6::internal::float_specs, fmt::v6::internal::buffer<char>&)'
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > fmt::v6::internal::grouping_impl<char>(fmt::v6::internal::locale_ref)'
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `int fmt::v6::internal::format_float<long double>(long double, int, fmt::v6::internal::float_specs, fmt::v6::internal::buffer<char>&)'
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `int fmt::v6::internal::snprintf_float<long double>(long double, int, fmt::v6::internal::float_specs, fmt::v6::internal::buffer<char>&)'
/usr/bin/ld: /home/shic/microros_ws/install/microxrcedds_agent/lib/libmicroxrcedds_agent.so.2.0.0: undefined reference to `int fmt::v6::internal::format_float<double>(double, int, fmt::v6::internal::float_specs, fmt::v6::internal::buffer<char>&)'
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/micro_ros_agent.dir/build.make:173: micro_ros_agent] Error 1
make[1]: *** [CMakeFiles/Makefile2:78: CMakeFiles/micro_ros_agent.dir/all] Error 2
make: *** [Makefile:141: all] Error 2
Failed <<< micro_ros_agent [24.5s, exited with code 2]
Summary: 5 packages finished [5min 28s]
1 package failed: micro_ros_agent
2 packages had stderr output: micro_ros_agent microxrcedds_agent
Additional information
I could not find any similar issue, although I tried to pull the eProsima/Micro-XRCE-DDS-Agent repo and building the workspace again using colcon build still the same issue.
I'm relatively new to ROS and do not have much knowledge regarding it, pardon me if I had missed something,
Thanks in advance.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Activity
pablogs9 commentedon Apr 5, 2021
Related: micro-ROS/micro-ROS-demos#43
pablogs9 commentedon Apr 5, 2021
Which compiler are you using
gccorclang?shic15 commentedon Apr 5, 2021
Default ROS2 compiler, gcc.
pablogs9 commentedon Apr 5, 2021
I have followed the tutorial instructions and it builds seamlessly:
https://asciinema.org/a/cHjRD383IpX5EJxx1H8rsJmFx
shic15 commentedon Apr 5, 2021
That's weird, even I tried installing micro ros thrice after completely deleting the workspace.
Could the results be different cause you're using docker? or is the problem somehow related with ROS2 installation?
pablogs9 commentedon Apr 5, 2021
Could you share the files inside
logfolder for micro xrce dds agent and micro ros agent?shic15 commentedon Apr 5, 2021
Sure, I've attached the zip file of the latest build in the log folder.
uros_log.zip
pablogs9 commentedon Apr 6, 2021
Please, delete the folders
buildinstallandlogand rebuild the micro-ROS agent and then attach here the log folder.shic15 commentedon Apr 6, 2021
I rebuild everything from scratch as I was getting some errors. This is a fresh install and build.
log.zip
pablogs9 commentedon Apr 6, 2021
I have seen that you have a custom installation of ROS 2 Foxy in
/home/shic/ros2_foxy/ros2-linux.Does this problem happen with a ROS 2 installation from binaries with
apt?Do you have installed
sudo apt-get install -y libfmt-dev?shic15 commentedon Apr 6, 2021
I didn't make any customizations while installing, directly installed ROS2 from here, and don't think I got a similar error there.
Are the instructions appropriate for learning purposes? There is another page for installation here, should I uninstall and proceed with that?
The fmt library is already installed.
shic15 commentedon Apr 7, 2021
I did try reinstalling ros2 but still no help. The same error occurs.
I have attached the log folder again if that helps to figure out the issue.
log.zip
pablogs9 commentedon Apr 8, 2021
Well, since this is not a reproducible issue, do you have any inconvenience in using any of the other options:
docker run -it --rm --net=host microros/micro-ros-agent:foxy udp4 --port 8888 -v6shic15 commentedon Apr 8, 2021
Not really, I'm ready to use whatever works. Just that I'm a newbie to this so approached the solution which had simple documentation.
To use the snap package I need to follow the tutorials till building the firmware
, then use snap package commands for creating and building the agent, right?
pablogs9 commentedon Apr 8, 2021
I prefer the docker version, but the snap package should work, just follow the instructions in the snap webpage
shic15 commentedon Apr 8, 2021
Finally got lucky with the dockerized micro_ros_agent. Also TIL about docker and it is pretty crazy what you can do with it, zero environment setup efforts full plug and play. Thanks for the help.