Ask Your Question

unable to build qt gui packadges: catkin_make must be invoked in the root of workspace

asked 2016-07-09 21:35:12 -0600

sadisari gravatar image

updated 2016-07-09 23:48:05 -0600

Hi all,

Newbie to ROS, I have downloaded "qt_gui_core" under my "ros_ws" (/ros_ws/qt_gui_core/qt_gui_core) and complied with cmake ./CMakeLists.txt successfully. When I try to run catkin_make to build I get the error message: The specified base path "/ros_ws/qt_gui_core/qt_gui_core" contains a package but "catkin_make" must be invoked in the root of workspace.

What am I doing wrong? How is one supposed to compile these packages without a catkin_ws and under ros_ws? also, qt_gui_core contains many subdirectories (qt_dotgraph, qt_gui_cpp...) am I correct by assuming the get built if I successfully build qt_gui_core/qt_gui_core?

Thank you very much

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2016-07-11 01:32:20 -0600

mgruhler gravatar image

Check out the tutorials on how to create a proper workspace for ROS/catkin.

Note that there is no difference between a ROS workspace and a catkin workspace. The layout for a workspace is typically <PATH_TO_ROOT>/src/<PACKAGES>. Choose <PATH_TO_ROOT> how you see fit, put all packages in the src folder below (in your case, the qt_gui_core package). You can have multiple packages in src.

Before you compile, go to the src directory and call catkin_init_workspace, remember to call source /opt/ros/<DISTRO>/setup.bash (where <DISTRO> is indigo, jade, kinetic, whatever you have).

You don't need to call cmake manually, catkin_make will do that.

After you compiled, call source <PATH_TO_ROOT>/devel/setup.bash after compilation to actually use this workspace.

edit flag offensive delete link more


Before you compile, go to the src directory and call catkin_init_workspace [..]

That's not actually necessary: catkin_make (or catkin build) will do that automatically for you.

gvdhoorn gravatar image gvdhoorn  ( 2016-07-11 03:19:17 -0600 )edit

@gvdhoorn, really? Nice. Didn't know that ;-)

mgruhler gravatar image mgruhler  ( 2016-07-11 04:26:44 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2016-07-09 21:35:12 -0600

Seen: 258 times

Last updated: Jul 11 '16