Catkin build error in Exercise 2.5

I’m getting an error related to this line of code in the CMakeLists.txt:

add_dependencies(publish_age topics_25_generate_messages_cpp)

The error says that

The dependency target “topics_25_generate_messages_cpp” of target
"publish_age " does not exist.

Not to restate the obvious, but this error means that there is a problem with either your cmake file, or the file it is referencing.

Can you provide more info? What is your intent? Can you share the location and contents of the topics_25_generate_messages_cpp file? There are several things that can cause cmake errors

1 Like