1

I use R statistics ("r-base") on my computer and recently, by mistake, I ran the following command in terminal:

sudo apt-get remove r-base-core

Of course this removed R from my computer. To undo my mistake, I tried to reinstall but I get the following message:

Some packages could no be installed. This might mean that you requested an 
impossible situation or, if you are using a unstable distribution, 
that some packages requested were not created or removed from "incoming". 
The following information might help to solve the problem:

These Packages have unmet dependencies:  
 r-base :
     Depends: r-base-core (>= 3.2.5-1precise0) but won't be installed
     Depends: r-recommended (= 3.2.5-1precise0) but won't be installed
     Recommends: r-base-html but won't be installed

I tried a lot of things to solve this problem. I also followed instructions on

"Package dependencies cannot be resolved" error when installing software

However, I got nothing. I've tried sudo apt-get install -f, and also to manually install the dependencies and recommendentions above (that is, I used sudo apt-get install r-base.html , sudo apt-get install r-recommended.html and sudo apt-get install r-base-core) but again I get frustrated. When I type these commands It gets the same error, but with new unmet dependencies.

2 Answers 2

0

You could try to install it with help of aptitude, gdebi, or synaptic which handles these types of problems automatically.

sudo aptitude install <package_name> in the terminal or just type aptitude in the terminal.

0

First off, A couple of questions: What does cat /etc/lsb-release say?

Second, looks like the packages your system is looking for were built for Ubuntu Precise.

I would suggest doing a apt-get update and then apt-get -f install. If this still fails, you may have to resort to using Launchpad.net to rebuild the Ubuntu Precise dependencies you need for your current lsb-release version.

I have actually done this for a few packages that exist in Trusty that don't exist in Xenial for me but some of my other programs still needed.

I created my own Launchpad.net corner with a special PPA for my own use. I then use Ubuntu Primary Package archive to copy packages to my PPA repo and set the destination build release appropriately for the release I want. Before I upgraded to Xenial, I was using Trusty and copied some packages from Wily and had them rebuilt for Trusty. You still have to go through the build logs if anything fails and copy dependent packages to your PPA repo, but eventually everything builds and can be used from your PPA. You may need to copy packages from other PPAs, and you can do so, but you need to use their "copy-packages" link instead of the one I just provided.

0

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