Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I don't know if this will be helpful to you or not, but I was getting a very similar error (add_custom_target cannot create target...) with another package, and it turned out that the CMakeLists and package.xml dependencies were specified incorrectly (in this case, you'd want to check the dependencies of rqt_commmon_plugins).

It was really confusing because the error message implied that the package (i.e. rqt_common_plugins) was trying to explicitly build the same target (roscpp_generate_messages_cpp), but in fact it was just an artifact from poorly-defined dependencies. Go figure.

I don't know if this will be helpful to you or not, but I was getting a very similar error (add_custom_target cannot create target...) with another package, and it turned out that the CMakeLists and package.xml dependencies were specified incorrectly (in this case, you'd want to check the dependencies of rqt_commmon_plugins).

It was really confusing because the error message implied that the package (i.e. rqt_common_plugins) was trying to explicitly build the same target (roscpp_generate_messages_cpp), but in fact it was just an artifact from poorly-defined dependencies. Go figure.

EDIT: Here's the commit that fixed the problem in my package: https://github.com/danepowell/omni_description/commit/b3a738afd01cb58c6d4ab33c1ff7dd5f3aa3c9b0