I have a problem in kdl_parser
http://wiki.ros.org/kdl_parser/Tutori...
I use Ubuntu 16.04, ROS(kinetic version). I want do do that tutorial. but I think it is not newly-released version. So I have to change some part of those
<build_depend package="kdl_parser" /> -====> <build_depend>kdl_parser</build_depend>
...
<run_depend package="kdl_parser" /> ====> <exec_depend>kdl_parser</exec_depend>
And I try to do the first one.
KDL::Tree my_tree;
if (!kdl_parser::treeFromFile("filename", my_tree)){
ROS_ERROR("Failed to construct kdl tree");
return false;
}
I tried to change the filename, and I tried to do another things(from 2.2 From the parameter server to 2.4From a URDF model ) But, I failed to do catkin_make. Following is the error message.
CMakeFiles/parser.dir/src/parser.cpp.o: In function `main':
parser.cpp:(.text+0x67): undefined reference to `KDL::Tree::Tree(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
parser.cpp:(.text+0xc8): undefined reference to `kdl_parser::treeFromFile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, KDL::Tree&)'
CMakeFiles/parser.dir/src/parser.cpp.o: In function `KDL::TreeElement::~TreeElement()':
parser.cpp:(.text._ZN3KDL11TreeElementD2Ev[_ZN3KDL11TreeElementD5Ev]+0x27): undefined reference to `KDL::Segment::~Segment()'
parser.cpp:(.text._ZN3KDL11TreeElementD2Ev[_ZN3KDL11TreeElementD5Ev]+0x38): undefined reference to `KDL::Segment::~Segment()'
collect2: error: ld returned 1 exit status
testbot_description/CMakeFiles/parser.dir/build.make:120: recipe for target '/home/jeong/catkin_ws/devel/lib/testbot_description/parser' failed
make[2]: *** [/home/jeong/catkin_ws/devel/lib/testbot_description/parser] Error 1
CMakeFiles/Makefile2:13351: recipe for target 'testbot_description/CMakeFiles/parser.dir/all' failed
make[1]: *** [testbot_description/CMakeFiles/parser.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2
Invoking "make -j4 -l4" failed