Can't build with mrpt-1.5.x
gyubeomim opened this issue · 3 comments
Hello,
Thank you for sharing the awesome repository in advance.
but I've encountered a build problem.
my environment is Ubuntu 16.04 LTS, mprt-1.5.8, gcc-5, g++-5
I tried to build with mrpt-1.5.8, It generates error message like below.
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp: In function ‘int main(int, char**)’:
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp:306:48: error: no matching function for call to ‘mrpt::poses::CPosePDFParticles::resetDeterministic(mrpt::math::TPose2D, std::deque<mrpt::bayes::CProbabilityParticle<sparsembs::TMBState_Particle<sparsembs::CDynamicSimulator_Indep_dense> >, std::allocator<mrpt::bayes::CProbabilityParticle<sparsembs::TMBState_Particle<sparsembs::CDynamicSimulator_Indep_dense> > > >::size_type)’
mrpt::math::TPose2D(), pf.m_particles.size());
^
In file included from /home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp:8:0:
/usr/local/include/mrpt/base/include/mrpt/poses/CPosePDFParticles.h:58:10: note: candidate: void mrpt::poses::CPosePDFParticles::resetDeterministic(const mrpt::poses::CPose2D&, size_t)
void resetDeterministic(
^
/usr/local/include/mrpt/base/include/mrpt/poses/CPosePDFParticles.h:58:10: note: no known conversion for argument 1 from ‘mrpt::math::TPose2D’ to ‘const mrpt::poses::CPose2D&’
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp:351:6: error: ‘getRandomGenerator’ is not a member of ‘mrpt::random’
mrpt::random::getRandomGenerator().drawGaussian1D(
^
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp:375:43: error: ‘class mrpt::utils::copy_ptr<mrpt::poses::CPose2D>’ has no member named ‘phi’
orientation_averager.m_particles[i].d.phi = atan2(
^
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp: In function ‘void pf_initialize_uniform_distribution(sparsembs::CMultiBodyParticleFilter&, sparsembs::CModelDefinition&)’:
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp:524:5: error: ‘getRandomGenerator’ is not a member of ‘mrpt::random’
mrpt::random::getRandomGenerator().drawUniform(-M_PI, M_PI);
^
/home/edward/gitrepo/multibody-state-estimation/examples/pf_test1/main.cpp:528:6: error: ‘getRandomGenerator’ is not a member of ‘mrpt::random’
mrpt::random::getRandomGenerator().drawUniform(-20, 20);
^
/home/edward/gitrepo/multibody-state-estimation/examples/ex_four_bars/main.cpp: In function ‘void buildParameterizedMBS(size_t, size_t, sparsembs::CModelDefinition&, double)’:
/home/edward/gitrepo/multibody-state-estimation/examples/ex_four_bars/main.cpp:35:25: error: ‘getRandomGenerator’ is not a member of ‘mrpt::random’
auto randomGenerator = mrpt::random::getRandomGenerator();
Then I searched getRandomGenerator() in mrpt-1.5.8 source code, it doesn't exist. I don't want to build mrpt-2.0.0 in Ubuntu 16.04 machine becuase it needs gcc-7 version which is not mostly used version in 16.04.
Is there any other way to build this repo? Thank you!
Hi @tigerk0430 ,
Thanks for the feedback!
Honestly, we are quite overwhelmed and keeping projects backwards-compatible with mrpt1 is not a priority... You can easily upgrade Xenial to gcc-7 with these steps, and keep both versions if you want to.
I'll keep this one open just in case someday we fix builds for mrpt1...
Cheers.
Then, I'll try to use gcc-7 version following the link you shared.
Thank you for the comment! :-)
Since the latest version implementing factor graphs, this library won't support mrpt <2.0 anymore... So closing this old ticket!