open-rmf / free_fleet

A free fleet management system.
Apache License 2.0
157 stars 65 forks source link

error during building for ros2 #55

Closed Gryogor closed 3 years ago

Gryogor commented 3 years ago

Hello. During the installation tutorial I have come to the error during the execution of colcon build command. Here is the result of it:

gryogor@gryogor-Lenovo-Y520-15IKBN:~/server_ws$ colcon build
Starting >>> cyclonedds
Starting >>> rmf_fleet_msgs
Starting >>> ament_cmake_catch2
Starting >>> rmf_cmake_uncrustify
Finished <<< ament_cmake_catch2 [0.57s]                                                       
Starting >>> rmf_dispenser_msgs
Finished <<< rmf_cmake_uncrustify [0.60s]                                                     
Starting >>> rmf_utils
Finished <<< rmf_utils [2.94s]                                                                      
Starting >>> rmf_traffic_msgs
Finished <<< rmf_dispenser_msgs [24.8s]                                                             
Starting >>> rmf_traffic
Finished <<< rmf_fleet_msgs [27.1s]                                   
Starting >>> rmf_door_msgs
Finished <<< rmf_door_msgs [19.7s]                                    
Starting >>> rmf_lift_msgs
--- stderr: cyclonedds                                                   
You have called ADD_LIBRARY for library ddsc without any source files. This typically indicates a problem with your CMakeLists.txt file
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.google.inject.internal.cglib.core.$ReflectUtils$1 (file:/usr/share/maven/lib/guice.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain)
WARNING: Please consider reporting this to the maintainers of com.google.inject.internal.cglib.core.$ReflectUtils$1
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
---
Finished <<< cyclonedds [52.2s]
Starting >>> free_fleet
Finished <<< free_fleet [7.39s]                                             
Starting >>> rmf_ingestor_msgs
Finished <<< rmf_lift_msgs [13.2s]                                              
Starting >>> rmf_task_msgs
Finished <<< rmf_ingestor_msgs [17.7s]                                                
Starting >>> free_fleet_client_ros1
[78.884s] WARNING:colcon.colcon_cmake.task.cmake.build:Could not run installation step for package 'free_fleet_client_ros1' because it has no 'install' target
--- stderr: free_fleet_client_ros1
catkin not found so skipping this ROS1 package
CMake Warning:
  Manually-specified variables were not used by the project:

    CATKIN_INSTALL_INTO_PREFIX_ROOT

---
Finished <<< free_fleet_client_ros1 [1.25s]
Starting >>> free_fleet_server_ros2
Finished <<< rmf_task_msgs [24.6s]                                                     
Starting >>> rmf_workcell_msgs
Finished <<< free_fleet_server_ros2 [11.2s]                                            
Starting >>> ff_rviz_plugins_ros1
[91.241s] WARNING:colcon.colcon_cmake.task.cmake.build:Could not run installation step for package 'ff_rviz_plugins_ros1' because it has no 'install' target
--- stderr: ff_rviz_plugins_ros1
catkin not found so skipping this ROS1 package
CMake Warning:
  Manually-specified variables were not used by the project:

    CATKIN_INSTALL_INTO_PREFIX_ROOT

---
Finished <<< ff_rviz_plugins_ros1 [1.20s]
Starting >>> ff_examples_ros1
--- stderr: rmf_traffic                                                                
In file included from /usr/include/eigen3/Eigen/LU:34:0,
                 from /usr/include/eigen3/Eigen/Geometry:16,
                 from /home/gryogor/server_ws/src/rmf_core/rmf_traffic/src/rmf_traffic/geometry/SimplePolygon.hpp:24,
                 from /home/gryogor/server_ws/src/rmf_core/rmf_traffic/src/rmf_traffic/geometry/SimplePolygon.cpp:21:
/usr/include/eigen3/Eigen/src/LU/Determinant.h: In member function ‘virtual rmf_traffic::geometry::CollisionGeometries rmf_traffic::geometry::SimplePolygonInternal::make_fcl() const’:
/usr/include/eigen3/Eigen/src/LU/Determinant.h:57:25: warning: ‘output’ may be used uninitialized in this function [-Wmaybe-uninitialized]
     return m.coeff(0,0) * m.coeff(1,1) - m.coeff(1,0) * m.coeff(0,1);
/usr/include/eigen3/Eigen/src/LU/Determinant.h:57:25: warning: ‘*((void*)& output +24)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
/usr/include/eigen3/Eigen/src/LU/Determinant.h:57:55: warning: ‘*((void*)& output +8)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
     return m.coeff(0,0) * m.coeff(1,1) - m.coeff(1,0) * m.coeff(0,1);
/usr/include/eigen3/Eigen/src/LU/Determinant.h:57:55: warning: ‘*((void*)& output +16)’ may be used uninitialized in this function [-Wmaybe-uninitialized]
/home/gryogor/server_ws/src/rmf_core/rmf_traffic/src/rmf_traffic/schedule/Negotiation.cpp: In static member function ‘static rmf_utils::optional<rmf_traffic::schedule::Negotiation> rmf_traffic::schedule::Negotiation::make(std::shared_ptr<const rmf_traffic::schedule::Viewer>, std::vector<long unsigned int>)’:
/home/gryogor/server_ws/src/rmf_core/rmf_traffic/src/rmf_traffic/schedule/Negotiation.cpp:897:10: error: could not convert ‘negotiation’ from ‘rmf_traffic::schedule::Negotiation’ to ‘rmf_utils::optional<rmf_traffic::schedule::Negotiation> {aka std::optional<rmf_traffic::schedule::Negotiation>}’
   return negotiation;
          ^~~~~~~~~~~
make[2]: *** [CMakeFiles/rmf_traffic.dir/src/rmf_traffic/schedule/Negotiation.cpp.o] Error 1
make[1]: *** [CMakeFiles/rmf_traffic.dir/all] Error 2
make: *** [all] Error 2
---
Failed   <<< rmf_traffic [1min 7s, exited with code 2]
Aborted  <<< ff_examples_ros1 [1.11s]
Aborted  <<< rmf_workcell_msgs [19.2s]                                                            
Aborted  <<< rmf_traffic_msgs [2min 1s]                                           

Summary: 14 packages finished [2min 4s]
  1 package failed: rmf_traffic
  3 packages aborted: ff_examples_ros1 rmf_traffic_msgs rmf_workcell_msgs
  5 packages had stderr output: cyclonedds ff_examples_ros1 ff_rviz_plugins_ros1 free_fleet_client_ros1 rmf_traffic
  3 packages not processed
aaronchongth commented 3 years ago

Hello @Gryogor !

Thanks for putting this issue! May I know which version of Ubuntu you are running?

Packages from the rmf_core repository have mainly migrated to use Ubuntu 20.04 due to some dependencies on C++17. There would be significant changes incoming for free_fleet, however in the meantime I will update the documentation accordingly.

Let me know if you have any other questions!

Gryogor commented 3 years ago

Thank you for the reply @aaronchongth ! I am using Ubuntu 18.04 with ROS1 Melodic and ROS2 Eloquent.

aaronchongth commented 3 years ago

Thanks for the reply @Gryogor! This branch contains a number of fixes and changes to the documentation to work with rmf_core packages, however they target at Ubuntu 20.04, ROS 1 Noetic and ROS 2 Foxy. The branch will be merged soon after some more testing, but it is usable for the most part.

I would advise to make the switch to 20.04, as that will be where future changes are targeted at. Let me know if you have any other questions!