Package.xml on creating srv (Unit 1)

Hello, just wanted to make sure.
Whenever you insert a package into find_package function from the CMake, you need to insert it as a build_depend in the package.xml right??

So, if we needed to insert in the CMake:

find_package(catkin REQUIRED COMPONENTS

The package.xml should look like this:


`I wanted to post this, since in the “solution” it says we just need to load std_msgs with build_depend.

Thanks from advance.
Ángel López

One way to kill this for sure is to pass your dependencies to the catkin_create_pkg command:

catkin_create_pkg whatever_package rospy std_msgs message_generation

Anyway, if something critical is missing the compilation will fail.

1 Like