"add_service_files()" is an unknown cmake command

asked 2023-02-21 08:47:24 -0600

jrsaffy gravatar image

I'm running ROS melodic on Ubuntu 18.04.6. I'm going through the Emil Vidmark tutorials if anyone is familiar. I'm trying to create a simple service:

int32 a
int32 b
int32 result

I have a service server node coded up and am adding my multiplier.srv to CMakeLists.txt:

add_service_files(FILES multiplier.srv)

I'm getting the error message:

CMake Error at tutorials/CMakeLists.txt:56 (add_service_files):
Unknown CMake command "add_service_files".

Let me know if you can help! Thanks in advance

edit retag flag offensive close merge delete


Could you provide a bit more context? How are you building your workspace?

joao.aguizo gravatar image joao.aguizo  ( 2023-02-22 05:06:17 -0600 )edit