Ask Your Question
4

how to clean out the catkin tree for different build type

asked 2013-01-05 17:10:39 -0500

updated 2013-01-05 20:25:02 -0500

How or what do you do to clean out a build of the catkin tree so that a different build can be done? I installed catkin workspace tree with the desktop-full packages for groovy. That build has build problem with fulle*. So I thought that I would start at the other end of the scale and build the ros-comm tree first. I am trying to build on a raspberry pi system. We have Fuerte built and running on it. I am also developing the build instructions for this in the wiki tree. I am coming to the result that I need to put together a cross-compilier enviroment to speed up the builds. With 500,000 sold in less than one year and a cost of $65.00 for a headless linux system. That doing this would be useful since I am working with the cube-spawn project to set up a multiple cube manufacturing environment.

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted
4

answered 2013-01-05 23:41:23 -0500

KruseT gravatar image

You can always delete a build folder in catkin and create a new one. You can also have differently named build folders. Catkin always builds all packages it finds in the src folder, so if you only want to build the ros_comm variant, you need to remove all packages that do not belong to that variant from the src folder.

If you need a "make clean" command that removes all items from your buildspace (and devel space) but keeps your build options i don't think we have such a thing, nor does cmake. But your buildspace is like a standard cmake build space.

So you can remove the devel folder, and remove all files and folders from your build folder except for CMakeCache.txt (which contains your build options). Calling cmake then will start a fresh build. So step-by-step:

  • remove undesired projects from src folder
  • delete devel folder
  • delete anything within build folder except for CMakeCache.txt
edit flag offensive delete link more

Comments

Suppose you deleted the CMakeCache.txt from the build directory as well, is there anyway to recover it short of running catkin_init_workspace?

nwb234 gravatar imagenwb234 ( 2014-07-31 05:35:23 -0500 )edit
0

answered 2013-01-06 05:06:34 -0500

updated 2013-01-06 05:07:28 -0500

The short answer is remove everything under the ros_catkin_ws directory and rerun the wstool command to install a new catkin build tree.

cd ros_catkin_sw

rm -rf *

wstool init -j8 src http://packages.ros.org/web/rosinstall/generate/raw/groovy/ros_comm

Then proceed with the standard build process.

edit flag offensive delete link more
0

answered 2013-01-05 19:07:19 -0500

tfoote gravatar image

Can you provide a little bit more information about your use case? And what are you trying to do a diff against? The recommended way to use catkin is with out of source builds, which means that you don't need to do this. If you follow the tutorials all build products should be produced outside your source tree.

edit flag offensive delete link more

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

Stats

Asked: 2013-01-05 17:10:39 -0500

Seen: 3,398 times

Last updated: Jan 06 '13