Robotics StackExchange | Archived questions

ROS Fuerte cross compiled on Nao V4 roscore pkg_resources raises DistributionNotFound: PyYAML

Hello!

I'm trying to cross compile ROS Fuerte for use on Nao V4 but when I attempt to run roscore on Nao the following exception is raised:

roscore
Traceback (most recent call last): 
 File "/home/nao/ros-nao/ros/fuerte/bin/roscore", line 4, in <module>
    import pkg_resources
  File "/home/nao/ros-nao/python/pkg_resources.py", line 2707, in <module>
    working_set.require(__requires__)
  File "/home/nao/ros-nao/python/pkg_resources.py", line 686, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/home/nao/ros-nao/python/pkg_resources.py", line 584, in resolve
    raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: PyYAML

Python path

 echo $PYTHONPATH
 /home/nao/ros-nao/ros/fuerte/lib/python2.7/dist-packages:/home/nao/ros-nao/python:

Yaml is present in /home/nao/ros-nao/python

ls -l /home/nao/ros-nao/python
drwxr-xr-x 2 nao nao 4096 Jun 18 08:06 rospkg
drwxr-xr-x 2 nao nao 4096 Jun 18 08:06 rospkg-1.0.28.egg-info
drwxr-xr-x 2 nao nao 4096 Jun 18 08:06 yaml

I am following the instructions described here: wiki.ros.org/nao/Tutorials/Cross-Compiling_NAO-V4

I have made some small adjustmets due to the fact that I use Python 2.7.2, Boost 1.48.

(The cross compiling is done on a Ubuntu 12.04 machine and Nao runs NaoQi 1.14.5)

uname -a
Linux Frej 3.5.0-45-generic #68~precise1-Ubuntu SMP Wed Dec 4 16:19:28 UTC 2013 i686 i686 i386 GNU/Linux
cat /etc/issue
Ubuntu 12.04.4 LTS \n \l
python --version
Python 2.7.3

The changes are:

  1. Section 1.2

    export ROSBOOSTVERSION="1.48.0"

    export CTC_DIR=/home/nao/linux32-nao-atom-cross-toolchain-1.14.3

  2. Section 1.6

Changing python2.6 to python2.7 in each path.

From my understanding pkg_resources should search the python path for it's dependencies?

Can anyone explain what could be the problem?

PS: I'm aware of wiki.ros.org/nao/Installation/local and I will try it as well.

Asked by jondy276 on 2014-06-18 03:50:30 UTC

Comments

Why Fuerte ? it is not supported anymore. http://wiki.ros.org/nao/Installation/compileFromVirtualNao should be better no ?

Asked by Vincent Rabaud on 2014-06-18 11:02:07 UTC

Only because it was the one used in the instructions. But the virtual machine approach appears to be a better way to do it. Thanks!

Asked by jondy276 on 2014-06-19 02:48:03 UTC

Answers

Rather than to fix the build issue I will be using http://wiki.ros.org/nao/Installation/compileFromVirtualNao

Asked by jondy276 on 2014-06-19 02:50:00 UTC

Comments