g2o的安装和卸载

g2o的安装和卸载

//要求cmake的版本3.14及以上。版本太低需要升级,查看 https://www.cnblogs.com/zsy-xmfc/p/17940959 

 

安装g2o

#安装依赖

sudo apt update

sudo apt install libeigen3-dev libsuitesparse-dev qtdeclarative5-dev qt5-qmake

#从git下载源码

#git clone https://github.com/RainerKuemmerle/g2o.git #github原地址

git clone https://gitee.com/zsy26226/g2o.git #使用国内的gitee地址

#进入源码目录
cd g2o

cat CMakeLists.txt | grep cmake_minimum_required #查看要求的cmake版本

mkdir build
cd build
cmake ..
make
sudo make install

#更新一下

sudo ldconfig

 

卸载go2g
sudo rm -rf /usr/local/lib/cmake/g2o /usr/local/bin/g2o* /usr/local/include/g2o /usr/local/lib/*g2o*

posted @ 2022-11-27 20:58  [zsy........]  阅读(372)  评论(0)    收藏  举报