https://www.jb51.cc/article/details/id/29136
1. 提示“CMAKE_CXX_COMPILER-NOTFOUND ”
具体形式:
Check for working CXX compiler: CMAKE_CXX_COMPILER-NOTFOUND
CMake Error: your CXX compiler: "CMAKE_CXX_COMPILER-NOTFOUND" was not found.
Please set CMAKE_CXX_COMPILER to a valid compiler path or name.
解决方法:
sudo apt-get install g++
2. 在ubuntu18.04系统上安装opencv但是在安装依赖包的过程中,有一个依赖包,libjasper-dev在使用命令
sudo apt-get install libjaster-dev
提示:无法定位软件包 libjasper-dev
后来google到解决办法,复制到这里
sudo add-apt-repository "deb http://security.ubuntu.com/ubuntu xenial-security main"
sudo apt update
sudo apt install libjasper1 libjasper-dev
成功的解决了问题,其中libjasper1是libjasper-dev的依赖包
3. 注意eigen 本人亲测Eigen3.2.10
wget https://bitbucket.org/eigen/eigen/get/3.2.10.tar.bz2 tar -xjf 3.2.10.tar.bz2
改文件夹名字
cd eigen mkdir build cd build cmake .. make sudo make install
4. ImportError: No module named catkin_pkg.package
注意Python版本 ros-melodic对应python3
5. 编译安装python3.7时
提示“ModuleNotFoundError: No module named ‘_ctypes‘”
解决办法
sudo apt-get update sudo apt-get upgrade sudo apt-get dist-upgrade sudo apt-get install build-essential python-dev python-setuptools python-pip python-smbus sudo apt-get install build-essential libncursesw5-dev libgdbm-dev libc6-dev sudo apt-get install zlib1g-dev libsqlite3-dev tk-dev sudo apt-get install libssl-dev openssl sudo apt-get install libffi-dev
安装完libffi后在编译安装就不报错了
6. 编译./build_ros.sh
提示[rosbuild] rospack found package "ORB_SLAM2" at "",but the current directory is "/home/angelo/ORB_SLAM2/Examples/ROS/ORB_SLAM2". You should double-check your ROS_PACKAGE_PATH to ensure that packages are found in the correct precedence order.
解决办法:输入
sudo ln -s ~/ORB_SLAM2/Examples/ROS/ORB_SLAM2 /opt/ros/<ros版本名>/share/ORB_SLAM2
7. 编译遇到找不到#include<Eigen/Dense>
解决办法:进入usr/local/include/eigen3将eigen3中的Eigen文件递归地复制到上一层文件夹(直接放到include):因为在很多程序中include时经常使用#include <Eigen/Dense>而不是使用的#include <eigen3/Eigen/Dense>所以要做下处理,否则一些程序在编译时会因找不到Eigen/Dense而报错。
8. 编译遇到libboost_system.so: 无法添加符号: DSO missing from command line
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。