tu-darmstadt-ros-pkg / cpp_introspection

8 stars 2 forks source link

Build fail #1

Closed ipa-bnm-rc closed 10 years ago

ipa-bnm-rc commented 10 years ago

Hi, I've installed rosmatlab so far as described in the wiki provided on github. Now I tried to create the workspace, also as written in the wiki. Everything went well, until now. When invoking catkin_make with the given options an error is thrown:

####
#### Running command: "make install -j16 -l16" in "/home/bnm-rc/rosmatlab_ws/build"
####
Scanning dependencies of target cpp_introspection
[  0%] [  0%] Building CXX object cpp_introspection/src/CMakeFiles/cpp_introspection.dir/introspection.cpp.o
Building CXX object cpp_introspection/src/CMakeFiles/cpp_introspection.dir/types.cpp.o
/home/bnm-rc/rosmatlab_ws/src/cpp_introspection/src/introspection.cpp: In function ‘cpp_introspection::PackagePtr cpp_introspection::load(const string&)’:
/home/bnm-rc/rosmatlab_ws/src/cpp_introspection/src/introspection.cpp:285:49: error: no matching function for call to ‘std::vector<std::basic_string<char> >::push_back(boost::filesystem3::path)’
/home/bnm-rc/rosmatlab_ws/src/cpp_introspection/src/introspection.cpp:285:49: note: candidate is:
In file included from /usr/include/c++/4.7/vector:65:0,
                 from /home/bnm-rc/rosmatlab_ws/src/cpp_introspection/include/introspection/forwards.h:35,
                 from /home/bnm-rc/rosmatlab_ws/src/cpp_introspection/include/introspection/field.h:32,
                 from /home/bnm-rc/rosmatlab_ws/src/cpp_introspection/src/introspection.cpp:29:
/usr/include/c++/4.7/bits/stl_vector.h:881:7: note: void std::vector<_Tp, _Alloc>::push_back(const value_type&) [with _Tp = std::basic_string<char>; _Alloc = std::allocator<std::basic_string<char> >; std::vector<_Tp, _Alloc>::value_type = std::basic_string<char>]
/usr/include/c++/4.7/bits/stl_vector.h:881:7: note:   no known conversion for argument 1 from ‘boost::filesystem3::path’ to ‘const value_type& {aka const std::basic_string<char>&}’
make[2]: *** [cpp_introspection/src/CMakeFiles/cpp_introspection.dir/introspection.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [cpp_introspection/src/CMakeFiles/cpp_introspection.dir/all] Error 2
make: *** [all] Error 2
Invoking "make" failed

What went wrong here??

Thanks for your answers!

ipa-bnm-rc commented 10 years ago

I solved it by changing the line 285 in the file [workspace_dir]/src/introspection.cpp to:

g_loaded_libraries.push_back(path.filename().string());

Now it works fine.