How to get the executable path of a node with C++?
Is there an easy way to get the whole path for a executable in a package with C++? like getPath for the package path? (ros/package.h)
Is there an easy way to get the whole path for a executable in a package with C++? like getPath for the package path? (ros/package.h)
In the main fonction,the argv[0] is the executable path, you can theck it as below:
int main(int argc,char ** argv){
printf("s%",argv[0]);
return 0;
}
I guess he rather wants to know where an executable for a specific package is. (A program in package A wants to find out where a specific program in package B is located)
Please start posting anonymously - your entry will be published after you log in or create a new account.
Asked: 2015-08-18 10:13:53 -0500
Seen: 494 times
Last updated: Aug 19 '15
programmatically load yaml parameters in C
problem in rospack find my package..
Getting joint state value given joint name in C++
Undefined reference in cvBridge.h
Couldn't find executable named publish below /home/jcardenasc93/catkin_ws/src/publisher
ROSBag C++ API -- reading message Header
Callback of actionlib_msgs::GoalStatusArray fails
Communication between ROS and wxWidgets