0
$\begingroup$

Rosanswers logo

I wanted to install ROS to try it out for the first time. I usually don't work on Linux, so I created a partition on my Notebook and I installed Ubuntu 16.04. I realized there aren't yet any binary distribution of ROS for most of the operating system and, if I understood correctly, also for Ubuntu 16.04. So I decided to build ROS Indigo from source by following this guide: http://wiki.ros.org/indigo/Installation/Source

From what I understood I only have problems when I execute the following command:

    ./src/catkin/bin/catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release

i.e. when it installs all dependencies recursively. The error I'm having is the following:

...

-- Using CATKIN_DEVEL_PREFIX: /home/nbro/ros_catkin_ws/devel_isolated/pcl_ros
-- Using CMAKE_PREFIX_PATH: /home/nbro/ros_catkin_ws/install_isolated
-- This workspace overlays: /home/nbro/ros_catkin_ws/install_isolated
-- Found PythonInterp: /usr/bin/python (found version "2.7.12") 
-- Using PYTHON_EXECUTABLE: /usr/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/nbro/ros_catkin_ws/build_isolated/pcl_ros/test_results
-- Found gtest sources under '/usr/src/gtest': gtests will be built
-- Using Python nosetests: /usr/bin/nosetests-2.7
-- catkin 0.6.18
-- Using these message generators: gencpp;genlisp;genpy
-- Checking to see if CXX compiler accepts flag -Wl,--version-script,"/home/nbro/ros_catkin_ws/build_isolated/pcl_ros/class_loader_hide_library_symbols__pcl_ros_io.script"
-- Checking to see if CXX compiler accepts flag -Wl,--version-script,"/home/nbro/ros_catkin_ws/build_isolated/pcl_ros/class_loader_hide_library_symbols__pcl_ros_io.script" - yes
-- Configuring done
CMake Warning (dev) at CMakeLists.txt:80 (add_dependencies):
  Policy CMP0046 is not set: Error on non-existent dependency in
  add_dependencies.  Run "cmake --help-policy CMP0046" for policy details.
  Use the cmake_policy command to set the policy and suppress this warning.

  The dependency target "pcl_ros_generate_messages_cpp" of target
  "pcl_ros_tf" does not exist.
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Generating done
-- Build files have been written to: /home/nbro/ros_catkin_ws/build_isolated/pcl_ros
==> make -j2 -l2 in '/home/nbro/ros_catkin_ws/build_isolated/pcl_ros'
Scanning dependencies of target pcd_to_pointcloud
Scanning dependencies of target pointcloud_to_pcd
make[2]: *** No rule to make target '/usr/lib/x86_64-linux-gnu/libproj.so', needed by '/home/nbro/ros_catkin_ws/devel_isolated/pcl_ros/lib/pcl_ros/pointcloud_to_pcd'.  Stop.
make[2]: *** Waiting for unfinished jobs....
make[2]: *** No rule to make target '/usr/lib/x86_64-linux-gnu/libproj.so', needed by '/home/nbro/ros_catkin_ws/devel_isolated/pcl_ros/lib/pcl_ros/pcd_to_pointcloud'.  Stop.
make[2]: *** Waiting for unfinished jobs....
[  3%] Building CXX object CMakeFiles/pcd_to_pointcloud.dir/tools/pcd_to_pointcloud.cpp.o
[  3%] Building CXX object CMakeFiles/pointcloud_to_pcd.dir/tools/pointcloud_to_pcd.cpp.o
CMakeFiles/Makefile2:104: recipe for target 'CMakeFiles/pcd_to_pointcloud.dir/all' failed
make[1]: *** [CMakeFiles/pcd_to_pointcloud.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/pointcloud_to_pcd.dir/all' failed
make[1]: *** [CMakeFiles/pointcloud_to_pcd.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2
<== Failed to process package 'pcl_ros': 
  Command '['/home/nbro/ros_catkin_ws/install_isolated/env.sh', 'make', '-j2', '-l2']' returned non-zero exit status 2

Reproduce this error by running:

I'm not sure how exactly I should solve this problem. I read around to know more about it. At the end I tried to run the following: sudo apt-get install ros-indigo-openni2-launch after having read the following Github issue: https://github.com/ros-simulation/gazebo_ros_pkgs/issues/337

Then I re-run the command to install the dependencies:

./src/catkin/bin/catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release

but I got another error (not sure now if it comes even before the previous error during the installation or after)!!! I don't know exactly what was this last error. I tried to create a script to automate the task of installing ROS Indigo based on the guide above, since this was taking more than 40 minutes!!! Here's the script that I run

#!/usr/bin/env bash

# Installing ROS Indigo from source
# More info at: http://wiki.ros.org/indigo/Installation/Source

# Install from source requires that you download and compile the source code on your own. 
# ROS Indigo ONLY supports Ubuntu Saucy and Trusty. 
# Other platforms are possible to use, but are not expected to work out of the box. 
# Target platforms are defined in 

sudo apt-get install python-rosdep python-rosinstall-generator python-wstool python-rosinstall build-essential

# 1.2 Initializing rosdep
sudo rosdep init

rosdep update

mkdir ~/ros_catkin_ws
cd ~/ros_catkin_ws

rosinstall_generator desktop_full --rosdistro indigo --deps --wet-only --tar > indigo-desktop-full-wet.rosinstall

wstool init -j8 src indigo-desktop-full-wet.rosinstall

rosdep install --from-paths src --ignore-src --rosdistro indigo -y

./src/catkin/bin/catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release

I run this script, which again took 40 minutes, and I got the first error again!! Very annoying!!! Is there a way so that I can install ROS Indigo for real (and not having to lose months trying to figure out the problems)??

I'm on a x86_64 system, if that helps for something.


Originally posted by nbro on ROS Answers with karma: 372 on 2017-03-05

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

I realized there aren't yet any binary distribution of ROS for most of the operating system and, [..] also for Ubuntu 16.04

ROS on Ubuntu is one of the combinations that is actually very well supported by the binary releases.

Unless you have a very strong desire or need to install Indigo on Ubuntu Xenial (16.04), I would recommend you install ROS Kinetic, following the regular installation instructions that will use the provided binary packages. This should be a 5 minute affair in most cases.

So I decided to build ROS Indigo from source by following this guide [..]

If you really must use ROS Indigo, either install Ubuntu Trusty (14.04) and again follow the regular installation instructions, or build it from sources, but be prepared to have to deal with (potentially) lots of dependency problems.

I don't feel it makes sense now to go through the rest of your post and try and diagnose your current issues before you've decided which course of action is appropriate for you and explained why.


PS: could you please tell us where / how you got the impression that there "aren't yet any binary distribution of ROS for most of the operating system", especially for Ubuntu?


Originally posted by gvdhoorn with karma: 86574 on 2017-03-05

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by nbro on 2017-03-05:
PS: could you please tell us where / how you got the impression that there "aren't yet any binary distribution of ROS for most of the operating system", especially for Ubuntu?

It's easy enough to get that impression even from the fact that ROS indigo has only binaries for Ubuntu 14.04.

Comment by gvdhoorn on 2017-03-05:
I was specifically asking about Ubuntu. The OS for which binaries will be build and which will be supported (even through from-source builds) are documented in REP-003, and also listed in the table at the top of the installation instructions.

Comment by nbro on 2017-03-05:
I still don't know the difference between ROS distributions, i.e. between Indigo and Kinetic, and thus how I should choose one over the other, and why. I will try to read something about that, if there is any useful article around.

Comment by gvdhoorn on 2017-03-05:
I think that is pretty well explained on the Distributions page.

But isn't the first thing to do -- before installing any software -- to figure out which version you'd like to install?

Comment by gvdhoorn on 2017-03-05:\

ROS indigo has only binaries for Ubuntu 14.04.

and Ubuntu Saucy (13.10) ..

Comment by nbro on 2017-03-05:
I told you. I'm not an active user of Ubuntu!! I didn't know that the different versions of ROS were because to target different versions of OS (Ubuntu), since I thought Ubuntu maintains backward compatibility, i.e. I assumed that if Indigo has not binary support for Ubuntu > 14.04, then no ROS had.

Comment by msadowski on 2017-03-06:
Go for kinetic. If you stumble upon some tutorials asking you to install a package using command like "apt-get install ros-indigo-package" then just change it to ".. ros-kinetic-package", in most cases it will work since most of the packages target Kinetic as well.

$\endgroup$

Your Answer

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