MISTLab / Swarm-SLAM

Sparse Decentralized Collaborative Simultaneous Localization and Mapping Framework for Multi-Robot Systems
https://lajoiepy.github.io/cslam_documentation/html/index.html
MIT License
391 stars 40 forks source link

Error when exeucting "colcon build" #41

Closed phoooooos closed 3 months ago

phoooooos commented 3 months ago

System: Ubuntu 20.04 ROS: foxy python: 3.9

When building cslam, an error occured and it looks relating to FLANN. Any kind advice would be appreciated!


Starting >>> cslam_common_interfaces Finished <<< cslam_common_interfaces [0.77s]
Starting >>> cslam --- stderr: cslam
CMake Warning (dev) at /usr/share/cmake-3.16/Modules/CMakeFindDependencyMacro.cmake:47 (find_package): Policy CMP0074 is not set: find_package uses _ROOT variables. Run "cmake --help-policy CMP0074" for policy details. Use the cmake_policy command to set the policy and suppress this warning.

CMake variable PCL_ROOT is set to:

/usr/local

For compatibility, CMake is ignoring the variable. Call Stack (most recent call first): /opt/ros/foxy/lib/x86_64-linux-gnu/rtabmap-0.21/RTABMapConfig.cmake:7 (find_dependency) /opt/ros/foxy/share/rtabmap_conversions/cmake/ament_cmake_export_dependencies-extras.cmake:21 (find_package) /opt/ros/foxy/share/rtabmap_conversions/cmake/rtabmap_conversionsConfig.cmake:41 (include) CMakeLists.txt:54 (find_package) This warning is for project developers. Use -Wno-dev to suppress it.

CMake Warning at /opt/ros/foxy/share/ament_cmake_pytest/cmake/ament_add_pytest_test.cmake:77 (message): The Python module 'pytest' was not found, pytests can not be run (e.g. on Ubuntu/Debian install the package 'python3-pytest') Call Stack (most recent call first): CMakeLists.txt:213 (ament_add_pytest_test)

CMake Warning at /opt/ros/foxy/share/ament_cmake_pytest/cmake/ament_add_pytest_test.cmake:77 (message): The Python module 'pytest' was not found, pytests can not be run (e.g. on Ubuntu/Debian install the package 'python3-pytest') Call Stack (most recent call first): CMakeLists.txt:213 (ament_add_pytest_test)

CMake Warning at /opt/ros/foxy/share/ament_cmake_pytest/cmake/ament_add_pytest_test.cmake:77 (message): The Python module 'pytest' was not found, pytests can not be run (e.g. on Ubuntu/Debian install the package 'python3-pytest') Call Stack (most recent call first): CMakeLists.txt:213 (ament_add_pytest_test)

CMake Error at CMakeLists.txt:156 (add_executable): Target "pose_graph_manager" links to target "FLANN::FLANN" but the target was not found. Perhaps a find_package() call is missing for an IMPORTED target, or an ALIAS target is missing?

CMake Error at CMakeLists.txt:156 (add_executable): Target "pose_graph_manager" links to target "FLANN::FLANN" but the target was not found. Perhaps a find_package() call is missing for an IMPORTED target, or an ALIAS target is missing?

CMake Error at CMakeLists.txt:140 (add_executable): Target "map_manager" links to target "FLANN::FLANN" but the target was not found. Perhaps a find_package() call is missing for an IMPORTED target, or an ALIAS target is missing?

CMake Error at CMakeLists.txt:140 (add_executable): Target "map_manager" links to target "FLANN::FLANN" but the target was not found. Perhaps a find_package() call is missing for an IMPORTED target, or an ALIAS target is missing?

CMake Generate step failed. Build files cannot be regenerated correctly.

Failed <<< cslam [2.52s, exited with code 1]

Summary: 1 package finished [3.49s] 1 package failed: cslam 1 package had stderr output: cslam 1 package not processed

lajoiepy commented 3 months ago

Hi! Have you resolved the problem? It seems system specific. Also, I see you are using ROS 2 Foxy so it might be an incompatibility issue. I strongly suggest that you use Docker instead of installing the packages directly. Look here for a Dockerfile example https://github.com/lajoiepy/cslam_experiments/blob/main/docker/Dockerfile.lidar