Ask Your Question

Add orocos libraries to ROS project

asked 2013-04-13 00:09:56 -0500

Roboticus gravatar image

updated 2014-01-28 17:16:10 -0500

ngrennan gravatar image

Hello. I have a problem with adding libraries, orocos components to ROS project. In CMakeLists.txt I add line:


But I still can't add any library from that folder to .cpp files, compiler doesn't see it. In addition, these folder isn't in the same path as my ROS project.

edit retag flag offensive close merge delete


are they custom libraries or orocos libraries such as bfl or kdl ? Which ros distro are you using ?

cagatay gravatar image cagatay  ( 2013-04-16 03:06:38 -0500 )edit

2 Answers

Sort by ยป oldest newest most voted

answered 2013-04-16 01:06:47 -0500

zumili gravatar image

Hello Roboticus,

I have added these lines for a ros project using the LabJack U3 Modul. It also has a separate library.

  • #directory where the library file is in
  • link_directories(/home/thomas/projects/labjack/exodrive/liblabjackusb)
  • #add the cpp files of your project
  • rosbuild_add_executable(labjack src/LabJack.cpp src/... some more files ...)
  • #link the library to the project (name of lib file:
  • target_link_libraries (labjack labjackusb)

As you can see the library is written without the pre-string "lib" and without the version number and type at the end. So the filename "" will become -> "labjackusb".

The command you used: include_directories(/home/user/my_lib_orocos) is more or less to describe where the header files are.

Hope this helps you with your problem.

Best regards, zumili

edit flag offensive delete link more

answered 2013-04-21 20:57:06 -0500

If you want to build your own Orocos based components/packages, please take a look at to learn how this is done.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2013-04-13 00:09:56 -0500

Seen: 112 times

Last updated: Apr 21 '13