ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

catkin cmake error with ros (error code 1)

asked 2016-11-10 14:45:20 -0600

dugrul gravatar image

Hello everyone, I am following the tutorial here to create a workspace with catkin: http://wiki.ros.org/catkin/Tutorials/... When I invoke catkin_make, I get this output:

ertugrul@Ertugrul-Laptop:~/ros/workspace/tutorial$ catkin_make
Base path: /home/ertugrul/ros/workspace/tutorial
Source space: /home/ertugrul/ros/workspace/tutorial/src
Build space: /home/ertugrul/ros/workspace/tutorial/build
Devel space: /home/ertugrul/ros/workspace/tutorial/devel
Install space: /home/ertugrul/ros/workspace/tutorial/install
####
#### Running command: "cmake /home/ertugrul/ros/workspace/tutorial/src -DCATKIN_DEVEL_PREFIX=/home/ertugrul/ros/workspace/tutorial/devel -DCMAKE_INSTALL_PREFIX=/home/ertugrul/ros/workspace/tutorial/install -G Unix Makefiles" in "/home/ertugrul/ros/workspace/tutorial/build"
####
-- Using CATKIN_DEVEL_PREFIX: /home/ertugrul/ros/workspace/tutorial/devel
-- Using CMAKE_PREFIX_PATH: /opt/ros/kinetic
-- This workspace overlays: /opt/ros/kinetic
-- Using PYTHON_EXECUTABLE: /home/ertugrul/anaconda2/bin/python
-- Using Debian Python package layout
-- Using empy: /usr/bin/empy
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/ertugrul/ros/workspace/tutorial/build/test_results
-- Found gtest sources under '/usr/src/gtest': gtests will be built
-- Using Python nosetests: /usr/bin/nosetests-2.7
Traceback (most recent call last):
  File "/opt/ros/kinetic/share/catkin/cmake/parse_package_xml.py", line 107, in <module>
    main()
  File "/opt/ros/kinetic/share/catkin/cmake/parse_package_xml.py", line 99, in main
    package = parse_package(args.package_xml)
  File "/home/ertugrul/anaconda2/lib/python2.7/site-packages/catkin_pkg/package.py", line 317, in parse_package
    return parse_package_string(f.read(), filename)
  File "/home/ertugrul/anaconda2/lib/python2.7/site-packages/catkin_pkg/package.py", line 450, in parse_package_string
    raise InvalidPackage('Error(s) in %s:%s' % (filename, ''.join(['\n- %s' % e for e in errors])))
catkin_pkg.package.InvalidPackage: Invalid package manifest "/opt/ros/kinetic/share/catkin/cmake/../package.xml": Error(s) in /opt/ros/kinetic/share/catkin/cmake/../package.xml:
- The manifest must not contain the following tags: depend, build_export_depend, buildtool_export_depend
CMake Error at /opt/ros/kinetic/share/catkin/cmake/safe_execute_process.cmake:11 (message):
  execute_process(/home/ertugrul/anaconda2/bin/python
  "/opt/ros/kinetic/share/catkin/cmake/parse_package_xml.py"
  "/opt/ros/kinetic/share/catkin/cmake/../package.xml"
  "/home/ertugrul/ros/workspace/tutorial/build/catkin/catkin_generated/version/package.cmake")
  returned error code 1
Call Stack (most recent call first):
  /opt/ros/kinetic/share/catkin/cmake/catkin_package_xml.cmake:63 (safe_execute_process)
  /opt/ros/kinetic/share/catkin/cmake/all.cmake:151 (_catkin_package_xml)
  /opt/ros/kinetic/share/catkin/cmake/catkinConfig.cmake:20 (include)
  CMakeLists.txt:52 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/ertugrul/ros/workspace/tutorial/build/CMakeFiles/CMakeOutput.log".
See also "/home/ertugrul/ros/workspace/tutorial/build/CMakeFiles/CMakeError.log".
Invoking "cmake" failed

I have tried anything I could find online, but I'm now clueless. Thank you for any help!

edit retag flag offensive close merge delete

Comments

Please include at least:

  • which OS this is
  • how you installed ROS (from sources, installed Debians)
  • the exact commands you used to create your workspace
  • the contents of /opt/ros/kinetic/share/catkin/cmake/../package.xml
gvdhoorn gravatar image gvdhoorn  ( 2016-11-11 02:45:42 -0600 )edit

3 Answers

Sort by ยป oldest newest most voted
6

answered 2017-08-17 06:39:51 -0600

Horse-man gravatar image

I solved this problem using:

pip install -U rosdep rosinstall_generator wstool rosinstall six vcstools
edit flag offensive delete link more

Comments

3

To avoid others to blindly copy-n-paste your approach: you should only install ROS Python packages using pip on systems which don't have Debian packages. On Debian systems you should use apt to update the installed binary packages.

Dirk Thomas gravatar image Dirk Thomas  ( 2017-08-17 07:33:08 -0600 )edit

It works for me.
And also, my python path need to designate, we can use -t for pip:
pip install -t /usr/local/lib/python2.7/site-packages/ 'your package'

Cabbage gravatar image Cabbage  ( 2017-10-06 01:27:57 -0600 )edit

It also worked for me I was getting similar error.

Nebula gravatar image Nebula  ( 2018-02-02 02:31:04 -0600 )edit

I'm having the same problem above too,but it doesn't work when I try the way above.I'm using ros2.

one-blue gravatar image one-blue  ( 2020-02-19 07:22:28 -0600 )edit
0

answered 2017-03-20 11:18:19 -0600

Moore gravatar image

pip install catkin_pkg which can be found from here

edit flag offensive delete link more

Comments

I'm having the same problem above and this does not solve the problem, not finding catkin_pkg is not the problem here. It is already installed via PIP in my case and I'm still getting this error.

alexe gravatar image alexe  ( 2017-04-17 17:07:00 -0600 )edit
0

answered 2023-03-02 05:40:46 -0600

in my case

pip3 install -U rosdep rosinstall_generator wstool rosinstall six vcstools

worked

ROS melodic - Ubuntu 18.04

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2016-11-10 14:45:20 -0600

Seen: 20,222 times

Last updated: Feb 19 '20