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

rosbag compilation on OSX 10.9 Xcode 5.0.1

asked 2013-11-10 19:58:45 -0500

Artem gravatar image

rosbag fails to compiles on OSX 10.9 due to forward declaration.

[  7%] [ 14%] [ 21%] [ 28%] [ 35%] [ 42%] [ 50%] Building CXX object CMakeFiles/rosbag.dir/src/bag.cpp.o
Building CXX object CMakeFiles/rosbag.dir/src/buffer.cpp.o
Building CXX object CMakeFiles/rosbag.dir/src/bz2_stream.cpp.o
Building CXX object CMakeFiles/rosbag.dir/src/player.cpp.o
Building CXX object CMakeFiles/rosbag.dir/src/query.cpp.o
Building CXX object CMakeFiles/rosbag.dir/src/chunked_file.cpp.o
Building CXX object CMakeFiles/rosbag.dir/src/message_instance.cpp.o
[ 57%] Building CXX object CMakeFiles/rosbag.dir/src/recorder.cpp.o
In file included from /Users/artemlenskiy/ros/hydro/src/rosbag/src/query.cpp:28:
In file included from /Users/artemlenskiy/ros/hydro/src/rosbag/include/rosbag/query.h:41:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/map:371:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__tree:602:16: error: field has incomplete type 'value_type'
      (aka 'rosbag::IndexEntry')
    value_type __value_;
               ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__tree:688:28: note: in instantiation of template class
      'std::__1::__tree_node<rosbag::IndexEntry, void *>' requested here
    typedef const typename __node::base                           __node_base;
                           ^
/Users/artemlenskiy/ros/hydro/src/rosbag/include/rosbag/query.h:117:47: note: in instantiation of template class 'std::__1::__tree_const_iterator<rosbag::IndexEntry, const
      std::__1::__tree_node<rosbag::IndexEntry, void *> *, long>' requested here
    std::multiset<IndexEntry>::const_iterator begin;
                                              ^
/Users/artemlenskiy/ros/hydro/src/rosbag/include/rosbag/query.h:51:8: note: forward declaration of 'rosbag::IndexEntry'
struct IndexEntry;
       ^
[ 64%] Building CXX object CMakeFiles/rosbag.dir/src/stream.cpp.o
[ 71%] Building CXX object CMakeFiles/rosbag.dir/src/time_translator.cpp.o
1 error generated.
make[2]: *** [CMakeFiles/rosbag.dir/src/query.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 78%] Building CXX object CMakeFiles/rosbag.dir/src/uncompressed_stream.cpp.o
make[1]: *** [CMakeFiles/rosbag.dir/all] Error 2
make: *** [all] Error 2
<== Failed to process package 'rosbag':

In fact src/rosbag/include/rosbag/query.h does contain forward definition struct IndexEntry; but I could not find any place where it is fully defined.

Any ideas how to resolve this issue?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
3

answered 2013-11-10 20:15:15 -0500

Hansg91 gravatar image

Yes, that forward declaration is not needed actually, that is if you include :

#include "rosbag/structures.h"

In

/Users/artemlenskiy/ros/hydro/src/rosbag/include/rosbag/query.h
edit flag offensive delete link more

Comments

Thanks again Hans, works like a champ!

Artem gravatar image Artem  ( 2013-11-10 23:43:10 -0500 )edit

Now having troubles compiling kdl_parser, again forward declaration. Will try to disable it, for now

Artem gravatar image Artem  ( 2013-11-11 04:31:18 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2013-11-10 19:58:45 -0500

Seen: 477 times

Last updated: Nov 10 '13