gentoo: genmsg error at catkin compile
Currently, I'm following this tutorial to install ROS indigo.
At compile I get the following complaint and I'm not really sure what to do or where to go from here.
Traceback (most recent call last):
File "/opt/ros/ros_catkin_ws/build_isolated/genmsg/catkin_generated/generate_cached_setup.py", line 19, in <module>
from catkin.environment_cache import generate_environment_script
ImportError: No module named catkin.environment_cache
CMake Error at /opt/ros/indigo/share/catkin/cmake/safe_execute_process.cmake:11 (message):
execute_process(/usr/bin/python
"/opt/ros/ros_catkin_ws/build_isolated/genmsg/catkin_generated/generate_cached_setup.py")
returned error code 1
Call Stack (most recent call first):
/opt/ros/indigo/share/catkin/cmake/all.cmake:185 (safe_execute_process)
/opt/ros/indigo/share/catkin/cmake/catkinConfig.cmake:20 (include)
CMakeLists.txt:3 (find_package)
-- Configuring incomplete, errors occurred!
See also "/opt/ros/ros_catkin_ws/build_isolated/genmsg/CMakeFiles/CMakeOutput.log".
<== Failed to process package 'genmsg':
Command '/opt/ros/indigo/env.sh cmake /opt/ros/ros_catkin_ws/src/genmsg -DCATKIN_DEVEL_PREFIX=/opt/ros/ros_catkin_ws/devel_isolated/genmsg -DCMAKE_INSTALL_PREFIX=/opt/ros/indigo -DCMAKE_BUILD_TYPE=Release -DSETUPTOOLS_ARG_EXTRA= -DSETUPTOOLS_DEB_LAYOUT=OFF' returned non-zero exit status 1
Reproduce this error by running:
==> cd /opt/ros/ros_catkin_ws/build_isolated/genmsg && /opt/ros/indigo/env.sh cmake /opt/ros/ros_catkin_ws/src/genmsg -DCATKIN_DEVEL_PREFIX=/opt/ros/ros_catkin_ws/devel_isolated/genmsg -DCMAKE_INSTALL_PREFIX=/opt/ros/indigo -DCMAKE_BUILD_TYPE=Release -DSETUPTOOLS_ARG_EXTRA= -DSETUPTOOLS_DEB_LAYOUT=OFF
UPDATE: Yes, the 15th step. I tried opening another terminal but end up just compiling less than before, I'm not sure if this will give you any clues but i'm not even really sure what the 14th step does, just thought it was telling ROS where to find python.
UPDATE 2: I tried following the ROS official source guide as well and end up on the same step now. The big reason I couldn't compile before was due to dependencies which have since been resolved (I think). Which leaves me at square one, why is python not importing catkin.environment?
Setting PYTHONPATH tells python where it should look for additional modules to import. Since ROS isn't installing python modules into the system directories, the PYTHONPATH needs to be set.
For debugging, I would start by searching the filesystem for
environment_cache*
and cross-check that with your PYTHONPATH.Were you able to resolve this?
(also, I doubt this is a gentoo specific problem)