Description:
When I execute make,I encountered a bug.
please help me,thinks.
The terminal output is as follows:
`Scanning dependencies of target KimeraRPGO
[ 6%] Building CXX object CMakeFiles/KimeraRPGO.dir/src/GenericSolver.cpp.o
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp: In member function ‘void KimeraRPGO::GenericSolver::removePriorsWithPrefix(const char&)’:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:138:77: error: no matching function for call to ‘dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose3 >(std::shared_ptrgtsam::NonlinearFactor&)’
if (boost::dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose3>(factor)) {
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(const boost::shared_ptr&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr const & r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:138:77: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘const boost::shared_ptr’
if (boost::dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose3>(factor)) {
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(boost::shared_ptr&&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr && r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:138:77: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘boost::shared_ptr’
if (boost::dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose3>(factor)) {
^
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:141:21: error: no matching function for call to ‘dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose3 >(std::shared_ptrgtsam::NonlinearFactor&)’
factor);
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(const boost::shared_ptr&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr const & r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:141:21: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘const boost::shared_ptr’
factor);
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(boost::shared_ptr&&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr && r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:141:21: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘boost::shared_ptr’
factor);
^
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:145:26: error: no matching function for call to ‘dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose2 >(std::shared_ptrgtsam::NonlinearFactor&)’
factor)) {
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(const boost::shared_ptr&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr const & r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:145:26: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘const boost::shared_ptr’
factor)) {
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(boost::shared_ptr&&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr && r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:145:26: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘boost::shared_ptr’
factor)) {
^
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:148:21: error: no matching function for call to ‘dynamic_pointer_cast<gtsam::PriorFactorgtsam::Pose2 >(std::shared_ptrgtsam::NonlinearFactor&)’
factor);
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(const boost::shared_ptr&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr const & r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:898:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:148:21: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘const boost::shared_ptr’
factor);
^
In file included from /usr/local/include/boost/shared_ptr.hpp:17,
from /usr/local/include/boost/format/alt_sstream.hpp:21,
from /usr/local/include/boost/format/internals.hpp:24,
from /usr/local/include/boost/format.hpp:38,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/Logger.h:8,
from /home/leng/Documents/Kimera-RPGO/include/KimeraRPGO/GenericSolver.h:16,
from /home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:9:
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: candidate: ‘template<class T, class U> boost::shared_ptr boost::dynamic_pointer_cast(boost::shared_ptr&&)’
template<class T, class U> shared_ptr dynamic_pointer_cast( shared_ptr && r ) BOOST_SP_NOEXCEPT
^~~~~~~~~~~~~~~~~~~~
/usr/local/include/boost/smart_ptr/shared_ptr.hpp:940:42: note: template argument deduction/substitution failed:
/home/leng/Documents/Kimera-RPGO/src/GenericSolver.cpp:148:21: note: ‘std::shared_ptrgtsam::NonlinearFactor’ is not derived from ‘boost::shared_ptr’
factor);
^
CMakeFiles/KimeraRPGO.dir/build.make:62: recipe for target 'CMakeFiles/KimeraRPGO.dir/src/GenericSolver.cpp.o' failed
make[2]: *** [CMakeFiles/KimeraRPGO.dir/src/GenericSolver.cpp.o] Error 1
CMakeFiles/Makefile2:153: recipe for target 'CMakeFiles/KimeraRPGO.dir/all' failed
make[1]: *** [CMakeFiles/KimeraRPGO.dir/all] Error 2
Makefile:140: recipe for target 'all' failed
make: *** [all] Error 2
`
Please give also the following information:
Kimera-RPGO branch, tag or commit used: master
GTSAM version used: 9902ccc0a4f62123e91f057babe3612a95c15c20 (tag: 4.2a8)
Operating system and version (e.g. Ubuntu 16.04 or Windows 10): ubuntu 18.04
Did you change the source code? (yes / no): no,