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

Error compiling eigen_msg on OSX 10.9

asked 2013-12-23 19:06:52 -0500

sagargp gravatar image

updated 2013-12-26 06:11:52 -0500

William gravatar image

I'm trying to build Hydro on OSX Mavericks by following the guide on the wiki. I am using an up-to-date homebrew, which got me this far. After several days of tracking down and fixing other compiler errors, I'm finally stuck on eigen_conversions and in particular eigen_msg.

./src/catkin/bin/catkin_make_isolated --install fails with an error having to do with implicit instantiation of undefined template 'std::allocator<void>'. The full make output is below. Any ideas? Is this an issue relating to clang on OSX? Do I need to update some include paths?

==> Processing catkin package: 'eigen_conversions'
==> Building with env: '/Users/sagar/workspace/ros_catkin_ws/install_isolated/env.sh'
Makefile exists, skipping explicit cmake invocation...
==> make cmake_check_build_system in '/Users/sagar/workspace/ros_catkin_ws/build_isolated/eigen_conversions'
==> make -j4 -l4 in '/Users/sagar/workspace/ros_catkin_ws/build_isolated/eigen_conversions'
[ 50%] Building CXX object CMakeFiles/eigen_conversions.dir/src/eigen_msg.cpp.o
In file included from /Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/src/eigen_msg.cpp:31:
In file included from /Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/include/eigen_conversions/eigen_msg.h:37:
In file included from /Users/sagar/workspace/ros_catkin_ws/install_isolated/include/std_msgs/Float64MultiArray.h:51:
/Users/sagar/workspace/ros_catkin_ws/install_isolated/include/std_msgs/MultiArrayLayout.h:71:89: error: implicit instantiation of undefined template 'std::allocator<void>'
   typedef std::vector< ::std_msgs::MultiArrayDimension_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::std_msgs::MultiArrayDimension_<ContainerAllocator> >::other >  _dim_type;
                                                                                        ^
/Users/sagar/workspace/ros_catkin_ws/install_isolated/include/std_msgs/Float64MultiArray.h:72:16: note: in instantiation of template class 'std_msgs::MultiArrayLayout_<std::allocator<void> >' requested here
  _layout_type layout;
               ^
/Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/include/eigen_conversions/eigen_msg.h:97:8: note: in instantiation of template class 'std_msgs::Float64MultiArray_<std::allocator<void> >' requested
      here
  if (m.layout.dim.size() != 2)
       ^
/Users/sagar/workspace/ros_catkin_ws/install_isolated/include/ros/message_forward.h:33:28: note: template is declared here
template<typename T> class allocator;
                           ^
In file included from /Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/src/eigen_msg.cpp:31:
In file included from /Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/include/eigen_conversions/eigen_msg.h:37:
In file included from /Users/sagar/workspace/ros_catkin_ws/install_isolated/include/std_msgs/Float64MultiArray.h:51:
/Users/sagar/workspace/ros_catkin_ws/install_isolated/include/std_msgs/MultiArrayLayout.h:71:118: error: 'rebind' following the 'template' keyword does not refer to a template
   typedef std::vector< ::std_msgs::MultiArrayDimension_<ContainerAllocator> , typename ContainerAllocator::template rebind< ::std_msgs::MultiArrayDimension_<ContainerAllocator> >::other >  _dim_type;
                                                                                                                     ^~~~~~
In file included from /Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/src/eigen_msg.cpp:31:
In file included from /Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/include/eigen_conversions/eigen_msg.h:37:
/Users/sagar/workspace/ros_catkin_ws/install_isolated/include/std_msgs/Float64MultiArray.h:74:41: error: implicit instantiation of undefined template 'std::allocator<void>'
   typedef std::vector<double, typename ContainerAllocator::template rebind<double>::other >  _data_type;
                                        ^
/Users/sagar/workspace/ros_catkin_ws/src/eigen_conversions/include/eigen_conversions/eigen_msg.h:97:8: note: in instantiation of template class 'std_msgs::Float64MultiArray_<std::allocator<void> >' requested
      here
  if (m.layout.dim.size() != 2)
       ^
/Users/sagar/workspace/ros_catkin_ws/install_isolated/include/ros/message_forward.h:33:28: note: template is declared here
template<typename T> class allocator;
                           ^
In file included from /Users/sagar/workspace ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2013-12-24 21:00:13 -0500

jensenb gravatar image

updated 2013-12-26 16:04:51 -0500

tfoote gravatar image

The issue you are seeing is caused by a problem in the roscpp_core upstream package and has been disused and fixed in https://github.com/ros/roscpp_core/pull/15. Unfortunately an updated release of this package has not been created for hydro, so you will have to make the change to package by hand.

cd <path to="" ros="" workspace="">/src/roscpp_traits/include/ros curl https://raw.github.com/ros/roscpp_core/8292898d4a90ecc8cf3d42c5ce4e51e14b02a8db/roscpp_traits/include/ros/message_forward.h -o message_forward.h

Here <path to="" ros="" workspace=""> is the path of your ros workspace.

edit flag offensive delete link more

Comments

Awesome! Thank you. This worked. Except now I'm running into other, unrelated problems. Currently stuck with "theora_image_transport/Packet.h not found". Any ideas?

sagargp gravatar image sagargp  ( 2013-12-26 19:51:23 -0500 )edit

I have not had a problem similar to that, sounds like something related to the image transport is broken.

jensenb gravatar image jensenb  ( 2013-12-27 20:59:45 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2013-12-23 19:06:52 -0500

Seen: 583 times

Last updated: Dec 26 '13