ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Build gazebo-grasp-pkgs on ROS noetic

asked 2020-12-01 20:16:51 -0500

robodude2020 gravatar image

I tried to build the gazebo-grasp-pkgs on ROS noetic. For ROS melodic, the compiling is successful. However, on ROS noetic with c++17, I meet the following errors:

error: deduced class type ‘Box’ in function return type
  116 | gz_math::Box GetBoundingBox(const T &t)
      |              ^~~~~~~~~~~~~~

error: template placeholder type ‘const Box<...auto...>’ must be followed by a simple declarator-id
  126 | GzVector3 GetBoundingBoxDimensions(const gz_math::Box &box);
      |                                    ^~~~~

 error: template placeholder type ‘const Box<...auto...>’ must be followed by a simple declarator-id
  126 | GzVector3 GetBoundingBoxDimensions(const gz_math::Box &box);

The detail of these errors are:

In file included from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:116:14: error: deduced class type ‘Box’ in function return type
  116 | gz_math::Box GetBoundingBox(const T &t)
      |              ^~~~~~~~~~~~~~
In file included from /usr/include/ignition/math6/ignition/math.hh:29,
                 from /usr/include/sdformat-9.2/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.2/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.2/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.2/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/ignition/math/Box.hh:42:11: note: ‘template<class Precision> class ignition::math::v6::Box’ declared here
   42 |     class Box
      |           ^~~
In file included from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:126:36: error: template placeholder type ‘const Box<...auto...>’ must be followed by a simple declarator-id
  126 | GzVector3 GetBoundingBoxDimensions(const gz_math::Box &box);
      |                                    ^~~~~
In file included from /usr/include/ignition/math6/ignition/math.hh:29,
                 from /usr/include/sdformat-9.2/sdf/Param.hh:33,
                 from /usr/include/sdformat-9.2/sdf/Element.hh:28,
                 from /usr/include/sdformat-9.2/sdf/Actor.hh:25,
                 from /usr/include/sdformat-9.2/sdf/sdf.hh:2,
                 from /usr/include/gazebo-11/gazebo/common/Battery.hh:25,
                 from /usr/include/gazebo-11/gazebo/common/common.hh:8,
                 from /usr/include/gazebo-11/gazebo/gazebo_core.hh:19,
                 from /usr/include/gazebo-11/gazebo/gazebo.hh:20,
                 from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:4,
                 from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/src/GazeboVersionHelpers.cpp:1:
/usr/include/ignition/math6/ignition/math/Box.hh:42:11: note: ‘template<class Precision> class ignition::math::v6::Box’ declared here
   42 |     class Box
      |           ^~~
In file included from /home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_grasp_plugin/src/GazeboGraspGripper.cpp:10:
/home/robo/catkin_ws/src/gazebo-grasp-pkgs/gazebo_version_helpers/include/gazebo_version_helpers/GazeboVersionHelpers.h:116:14: error: deduced class type ‘Box’ in function return type
  116 | gz_math::Box GetBoundingBox(const T &t)
      |              ^~~~~~~~~~~~~~
In file included from /usr/include/ignition/math6/ignition/math.hh:29,
                 from /usr/include/sdformat-9.2/sdf ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2020-12-10 12:52:10 -0500

Hi,

ROS Noetic uses gazebo 11 by default, and in that version the ignition::math::Box template is replaced by ignition::math::AxisAlignedBox.

Also, for the case of the gazebo_version_helpers package, there's a Noetic branch in the main repository https://github.com/JenniferBuehler/gazebo-pkgs/tree/noetic so you can use that one.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2020-12-01 20:16:51 -0500

Seen: 1,089 times

Last updated: Dec 10 '20