0
$\begingroup$

Rosanswers logo

Background: I am a user upgrade ros from electric to fuerte. In electric, I edit .bashrc and setup.* myself. In fuerte, I tried to get familiar with rosws to manage the workspace.

Problem: I have installed openni_camera and openni_launch, using the command

sudo apt-get install ros-fuerte-openni-camera
sudo apt-get install ros-fuerte-openni-launch

So the two packages were installed into opt/ros/fuerte/stacks, which is one of the workspaces.

I can access the folder and run rosmake. However, roscd, roslaunch rosrun cannot find the package openni_camera or openni_launch.

After a while, (I did not source any setup.sh or .bashrc file), roscd can find the package... May I know how can I manually add the two packages into the index.

I have another question. When I create a sandbox, if I directly copy a package into the sandbox, it will be automatically indexed and roscd can access the package. But if I copy the package into /fuerte_workspace, it cannot be indexed. I need to rosws set the folder as an workspace. But fuerte_workspace is already a workspace, so I am setting a workspace inside another one? And packages inside the sub-workspace can be automatically indexed also.

Though most of the time I do not have problems with rosws and the indexing, still want to have somebody can explain this to me in detail. Thx.


Originally posted by tianb03 on ROS Answers with karma: 710 on 2013-01-31

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

The rosws workspace does not get automatically "indexed" fully. Instead you can imagine that subfolders of the workspace are not "active", unless they get activated.

Only entries in the .rosinstall file are active, and being "indexed". The sandbox is only "indexed" if you have that in your .rosinstall file. rosws set adds a folder to your .rosinstall file, it does not mark the folder as a workspace, it marks the folder as being an active part of the workspace.

The indexing is using a cache file, so if you install or remove packages, the cache can be stale, and roscd and similar commands may not work correctly until the cache is refresehd. The

 $ rospack profile

command refreshes the cache manually.


Originally posted by KruseT with karma: 7848 on 2013-02-01

This answer was ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.