Exercise 4.4: Found the following, but they're either not files, or not executable

Hi, I just implemented the code in exercise 4.4 but it didn’t work.

user:~/catkin_ws$ rosrun action_client_pkg ardrone_action_client.cpp

[rosrun] Couldn't find executable named ardrone_action_client.cpp below /home/user/catkin_ws/src/action_client_pkg
[rosrun] Found the following, but they're either not files,
[rosrun] or not executable:
[rosrun]   /home/user/catkin_ws/src/action_client_pkg/src/ardrone_action_client.cpp

I already copied the contents of [ardrone_action_client.cpp], why cant I execute it?

Ok I found out, the .cpp part must be cut:

rosrun action_client_pkg ardrone_action_client

It worked.

1 Like