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

KDL, undefined reference to KDL::Chain

asked 2013-09-03 13:21:24 -0600

Franco gravatar image

Hello everyone!

I am having problems when trying to compile with rosmake a KDL example (the one found in the KDL website). I always get this output when doing rosmake

undefined reference to `KDL::Chain::~Chain()'

and a lot more of undefined reference... i did everything i could.. followed the ros instructions in order to get kdl up and running but i cannot get it to compile!

Note: i included the find_package(Orocos-kdl) in the CMakeLists but the problem persists...

Any help will be appreciated! thanks in advance, Franco

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2013-09-03 13:53:43 -0600

Franco gravatar image

updated 2013-09-03 16:44:11 -0600

I managed to get it compiled and linked!

For everyone: in the CMakeLists:



find_package(Eigen REQUIRED)
find_package(Orocos-KDL REQUIRED)

rosbuild_add_executable(prueba_kdl src/prueba.cpp)
target_link_libraries(${PROJECT_NAME} orocos-kdl)

Cheers Franco

edit flag offensive delete link more

answered 2013-09-04 08:45:03 -0600

moicez gravatar image

Hey! hello I had the exact same problem, but I was trying the tutorial for parsing a URDF to use the KDL library. Here is my solution: I also edit the CMakeLists.txt:

cmake_minimum_required(VERSION 2.8.3)

find_package(catkin REQUIRED)


add_executable(mykdl src/mykdl.cpp)
target_link_libraries(mykdl ${kdl_parser_LIBRARIES}   ${orocos_kdl_LIBRARIES} )


BTW I am on ubuntu 12.04 running groovy

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2013-09-03 13:21:24 -0600

Seen: 1,749 times

Last updated: Sep 04 '13