Ask Your Question

target link libraries for C++

asked 2014-06-29 05:53:01 -0600

updated 2014-06-29 05:57:42 -0600

I am using a very simple C++ program and in the CMakelists.txt, my program works for both target_link_libraries(myprogram ${roscpp_LIBRARIES}) and target_link_libraries(myprogram ${catkin_LIBRARIES}). Hence my question, for a C++ program which one is more suitable ?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2014-06-29 08:46:21 -0600

joq gravatar image

That depends on what your program needs.

Since roscpp is a catkin package, the latter does make sense. It will provide libraries from all the catkin packages you depend on.

edit flag offensive delete link more


@joq What all does the catkin package include ? Is there a list ?

Arkapravo gravatar image Arkapravo  ( 2014-06-29 15:14:11 -0600 )edit

Everything you found using ``find_package(catkin REQUIRED COMPONENTS roscpp ... )``

joq gravatar image joq  ( 2014-06-29 18:59:48 -0600 )edit

Your Answer

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

Add Answer

Question Tools

1 follower


Asked: 2014-06-29 05:53:01 -0600

Seen: 456 times

Last updated: Jun 29 '14