2

I am trying to install ros-desktop on Ubuntu16.04, ARM. However, my plan is to first download the .deb packages recursively using apt-get download and apt-rdepends as shown here and later install using dpkg ignoring some of the dependencies I don't want. (apt-get install won't let me ignore these dependencies, so I resorted to this method). But I encounter errors while downloading the package

E: Can't select candidate version from package xxx as it has no candidate

and many more such lines. Can you please suggest a work around for this.

Important Note: If the suggestion is apt-get update, I cannot perform it as some of the updated packages are not compatible and will crash my installed drivers. Besides this, is there a way I can successfully download and install manually?

FYI: the dependencies I am ignoring are mesa because I already have own libraries for implementation of opengl and I don't want these additional mesa packages to interfere. Thanks in advance.

4
  • Did you try excluding the package by using |grep -v "xxx", like in the second answer to the linked question?
    – Jos
    Mar 28, 2017 at 9:47
  • I did check that but since I have too many packages throwing that error, I was wondering if there was a simpler way without manually adding each of them. I'll probably have to do it manually then. Also, would excluding like this throw any errors while installing? or the installation will try and fetch them?
    – samhitha
    Mar 28, 2017 at 9:59
  • 1
    In that case, I'm beginning to think that it might be easier to modify the ros-desktop.deb file and remove the dependencies. Find a script file called videbcontrol on the internet, execute it and remove the unwanted packages from the "Depends:" line. Save the .deb file, and install it with dpkg.
    – Jos
    Mar 28, 2017 at 10:15
  • Hi again. I manually added the packages to |grep -v "xxx"as you suggested and now it throws the error Handler silently failed. Any ideas?
    – samhitha
    Mar 30, 2017 at 10:27

1 Answer 1

1

I found this link here working, as I encountered the same problems like you:

www.ostechnix.com/download-packages-dependencies-locally-ubuntu/

Roughly it works like this (replace keyword python by the name of your dependency, for me it was network-manager, and it worked nicely):

  1. $ sudo apt-cache depends python will list all python dependencies
  2. Output:

    python PreDepends: python-minimal Depends: python2.7 Depends: libpython-stdlib Conflicts: <python-central> Breaks: update-manager-core Suggests: python-doc Suggests: python-tk Replaces: python-dev

  3. Create a directory somewhere in your workspace: mkdir python

  4. Go into this directory: cd python

  5. Run a foreach loop on each dependency for all recommended, suggested and depending packages and pipe the errors into an errors.txt file:

    $ for i in $(apt-cache depends python | grep -E 'Depends|Recommends|Suggests' | cut -d ':' -f 2,3 | sed -e s/'<'/''/ -e s/'>'/''/); do sudo apt-get download $i 2>>errors.txt; done

  6. In errors.txt there should be some "W:" warnings about non-dropped privileges which you can ignore as it does not affect the downloaded results, which you can prove typing $ls -la, as you can prove for yourself, that every file is in place which was warned for (and as you probably don't need privelges for that step).

  7. After bringing the files i.E. with an USB stick to the target device you can go on with

    $ sudo dpkg -i * in the related (dependency) directory (in this case python and you should be able to install the files.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .