我想看到各个报错和包的依赖关系,比如在 catkin_make 的时候,可能会说缺某些包,要安装依赖,
在说依赖之前,再提一点,因为我用的是树莓派3b+,内存只有1G,在编译的时候很可能会由于内存不足导致编译失败,所以要添加一个swap,当然我装好ubuntu mate 18.04后默认已经有一个 /swapfile 了,只是其大小只有128M,干脆扩大到1G
sudo swapoff /swapfile
sudo dd if=/dev/zero of=/swapfile bs=64M count=16
#count的大小就是增加的swap空间的大小,64M是块大小,所以空间大小是bs*count=1024MB
sudo mkswap /swapfile
#把刚才空间格式化成swap格式
sudo swapon /swapfile
#启用swap
sudo swapon -s
#查看是否启用
如果报错 Could NOT find cv_bridge,那么执行如下安装即可
sudo apt-get install ros-melodic-cv-bridge
#sudo apt-get install ros-melodic-image-transport
报错Could NOT find depth_image_proc
sudo apt install ros-melodic-depth-image-proc -y
# sudo apt install ros-melodic-rgbd-launch -y
报错Could NOT find camera_info_manager
sudo apt install ros-melodic-camera-info-manager -y
报错
qmake: could not exec '/usr/lib/arm-linux-gnueabihf/qt4/bin/qmake': No such file or directory
CMake Error at /usr/share/cmake-3.10/Modules/FindQt4.cmake:1320 (message):
Found unsuitable Qt version "" from NOTFOUND, this code requires Qt 4.x
如果要简单一点,直接添加Qt4支持即可
sudo apt install qt4-default
如果要升级到QT5会有点麻烦
cd /usr/lib/arm-linux-gnueabihf/qt-default/qtchooser
sudo rm default.conf
sudo ln -s ../../../../share/qtchooser/qt5-arm-linux-gnueabihf.conf default.conf
sudo apt install qt5-default
修改 src/lidar/hector_slam/hector_geotiff/CMakeLists.txt,把
find_package(Qt4 4.6 COMPONENTS QtCore QtGui REQUIRED)
改为
find_package(Qt5 COMPONENTS Core Gui REQUIRED)
报错Could NOT find tf_conversions
sudo apt install ros-melodic-tf-conversions
报错 Could NOT find diagnostic_updater
sudo apt install ros-melodic-diagnostic-updater
报错 Could NOT find geographic_msgs
sudo apt install ros-melodic-geographic-msgs
报错 Could NOT find roslint
sudo apt-get install ros-melodic-roslint
报错
By not providing "FindPCL.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "PCL", but
CMake did not find one.
Could not find a package configuration file provided by "PCL" with any of
the following names:
PCLConfig.cmake
pcl-config.cmake
Add the installation prefix of "PCL" to CMAKE_PREFIX_PATH or set "PCL_DIR"
to a directory containing one of the above files. If "PCL" provides a
separate development package or SDK, be sure it has been installed.
sudo apt install ros-melodic-pcl-ros
# sudo apt install libpcl-dev
报错 Linux/XnLinuxUSB.cpp:29:10: fatal error: libusb-1.0/libusb.h: No such file or directory
#include <libusb-1.0/libusb.h>
^~~~~~~~~~~~~~~~~~~~~
sudo apt install libusb-1.0-0-dev
报错 fatal error: pcl_ros/point_cloud.h: No such file or directory
#include <pcl_ros/point_cloud.h>
^~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
sudo apt install ros-melodic-pcl-ros
报错 Could NOT find tf (missing: tf_DIR)
sudo apt install ros-melodic-tf -y
报错 Could NOT find tf2_geometry_msgs (missing: tf2_geometry_msgs_DIR)
sudo apt install ros-melodic-tf2-geometry-msgs -y