首页 > 其他分享> > 编译orb-slam2(add seg)的一些警告/usr/bin/ld: warning: libopencv_core.so.3.4, needed by ../Thirdparty/DBoW2/
编译orb-slam2(add seg)的一些警告/usr/bin/ld: warning: libopencv_core.so.3.4, needed by ../Thirdparty/DBoW2/
作者:互联网
1
/usr/bin/ld: warning: libopencv_core.so.3.4, needed by …/Thirdparty/DBoW2/lib/libDBoW2.so, not found (try using -rpath or -rpath-link)
2
./Examples/RGB-D/rgbd_tum: error while loading shared libraries: libopencv_core.so.3.4: cannot open shared object file: No such file or directory
解决
编译别人给的代码,注意删除原始的build相关文件,进行重新编译,否则进行的链接关系会基于已有的生成的编译文件进行链接
echo "Configuring and building Thirdparty/DBoW2 ..."
cd Thirdparty/DBoW2
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release
make -j
cd ../../g2o
echo "Configuring and building Thirdparty/g2o ..."
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release
make -j
cd ../../../
echo "Uncompress vocabulary ..."
cd Vocabulary
tar -xf ORBvoc.txt.tar.gz
cd ..
echo "Configuring and building ORB_SLAM2 ..."
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release
make -j
标签:bin,core,ld,Thirdparty,..,...,cd,build,DBoW2 来源: https://blog.csdn.net/weixin_43848456/article/details/122157151