I am trying to follow this site.
I want to realize this source on rviz.
I have done the following.
catkin_create_pkg pkg_name roscpp
Created CMakeList
Inserted source file
pkg_name/src/sorce.cpp
catkin_make
~/pkg_name$ catkin_make
Then, I got the following error
The specified base path "/home/usr/pkg_name" contains a package but "catkin_make" must be invoked in the root of workspace
How can this be resolved?
You have to first create a workspace. Follow this link. Then inside your workspace's src folder, you can create your package following this link. These are links to ROS Wiki tutorials which you should go through if you are new to ROS.