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

Revision history [back]

You can create your own library, like this:

ADD_LIBRARY( yourlibrary_name STATIC your_file_hpp_and_cpp ) TARGET_LINK_LIBRARIES( yourlibrary_name libraries_needed_by_your_library )

create node with your library rosbuild_add_executable(the_node_name src/file1.cpp ... src/filen.cpp ) target_link_libraries(the_node_name yourlibrary_name)

or simply add everything in rosbuild_add_executable(.....