1

While doing catkin_make ROS_MRPT_SLAM, I got following error

In file included from /usr/include/mrpt/base/include/mrpt/utils/CFileGZInputStream.h:12:0,
                 from /home/ian/catkin_ws/src/mrpt_slam/mrpt_ekf_slam_2d/include/mrpt_ekf_slam_2d/mrpt_ekf_slam_2d.h:11,
                 from /home/ian/catkin_ws/src/mrpt_slam/mrpt_ekf_slam_2d/src/mrpt_ekf_slam_2d.cpp:7:
/usr/include/mrpt/base/include/mrpt/utils/CStream.h: In member function ‘void mrpt::utils::CStream::WriteVariant(T)’:
/usr/include/mrpt/base/include/mrpt/utils/CStream.h:313:15: error: use of ‘auto’ in lambda parameter declaration only available with -std=c++14 or -std=gnu++14
   t.match([&](auto& o) { this->WriteObject(o); });
               ^
/usr/include/mrpt/base/include/mrpt/utils/CStream.h: In lambda function:
/usr/include/mrpt/base/include/mrpt/utils/CStream.h:313:45: error: no matching function for call to ‘mrpt::utils::CStream::WriteObject(int&)’
   t.match([&](auto& o) { this->WriteObject(o); });

I guess it's compatibility matter or something because there were missing header files and so on.

This is the ROS_PACKAGE wiki: http://wiki.ros.org/mrpt_slam

And I just followed instruction from official MRPT website.

If the developer or anyone who is familiar with mrpt toolkit sees this question, may I get some advice about these errors?

By the way, I installed mrpt toolkit using the following website's instruction: http://www.mrpt.org/MRPT_in_GNU/Linux_repositories.

4

1 回答 1

0

我是 MRPT 和部分 ROS 软件包的主要作者。

抱歉,您发现我们正处于 mrpt 系列 1.5.* 和基于 C++14 的新市长重写之间的过渡中,该重写目前在 git 中作为 mrpt 1.9.9 发布,最终将作为 2.0.0 发布.

这个转换必须传播到 ros 节点,但到目前为止我们只升级了 mrpt_navigation,mrpt_slam 在待办事项列表中。

所以:一个解决方案是安装 1.5.* 系列的 mrpt 版本,并从源代码构建 ros 包,注意检查名为compat-mrpt-1.5.

希望这可以帮助!

于 2017-08-23T23:46:42.737 回答