概述
SLAM十四讲编译Souphus出错解决办法
/usr/bin/c++ -DSophus_EXPORTS -I/usr/include/eigen3 -O3 -DNDEBUG -fPIC -Wall -Werror -Wno-unused-variable -Wno-unused-but-set-variable -Wno-unknown-pragmas -o CMakeFiles/Sophus.dir/sophus/so2.cpp.o -c /home/angus/Downloads/slambook-master/3rdparty/Sophus/sophus/so2.cpp
/home/angus/Downloads/slambook-master/3rdparty/Sophus/sophus/so2.cpp: In constructor ‘Sophus::SO2::SO2()’:
/home/angus/Downloads/slambook-master/3rdparty/Sophus/sophus/so2.cpp:32:26: error: lvalue required as left operand of assignment
32 | unit_complex_.real() = 1.;
| ^~
/home/angus/Downloads/slambook-master/3rdparty/Sophus/sophus/so2.cpp:33:26: error: lvalue required as left operand of assignment
33 | unit_complex_.imag() = 0.;
| ^~
make[2]: *** [CMakeFiles/Sophus.dir/build.make:66: CMakeFiles/Sophus.dir/sophus/so2.cpp.o] Error 1
make[2]: Leaving directory '/home/angus/Downloads/slambook-master/3rdparty/Sophus/build'
make[1]: *** [CMakeFiles/Makefile2:91: CMakeFiles/Sophus.dir/all] Error 2
make[1]: Leaving directory '/home/angus/Downloads/slambook-master/3rdparty/Sophus/build'
make: *** [Makefile:144: all] Error 2
将so2.cpp 中的
>unit_complex_.real() = 1.;
>unit_complex_.imag() = 0.;
改为
unit_complex_.real(1.);
unit_complex_.imag(0.);
即可解决
最后
以上就是娇气鱼为你收集整理的SLAM十四讲编译Souphus出错解决办法SLAM十四讲编译Souphus出错解决办法的全部内容,希望文章能够帮你解决SLAM十四讲编译Souphus出错解决办法SLAM十四讲编译Souphus出错解决办法所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复