Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have done the following:

sudo apt-get install vim-gnome

But I get the following:

vim-gnome : Depends: libruby1.8 (>= but is to be installed
E: Unable to correct problems, you have held broken packages.

I've done:

sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade

Contents of my /etc/apt/sources.list file:

deb oneiric main restricted
deb-src oneiric main restricted
deb oneiric-updates main restricted
deb-src oneiric-updates main restricted
deb oneiric universe
deb-src oneiric universe
deb oneiric-updates universe
deb-src oneiric-updates universe
deb oneiric multiverse
deb-src oneiric multiverse
deb oneiric-updates multiverse
deb-src oneiric-updates multiverse
deb oneiric-security main restricted
deb-src oneiric-security main restricted
deb oneiric-security universe
deb-src oneiric-security universe
deb oneiric-security multiverse
deb-src oneiric-security multiverse

But all to no avail. I always get the same error above.

What can I do to resolve?

share|improve this question
I wonder why is your libruby still at 1.8.6? The ubuntu repositories contain 1.8.7 ( Are you using the main repository? Enter gnome-control-center software and see the „Download from” setting. – lgarzo Nov 9 '11 at 15:50
It's set to download from Server for United States. – croceldon Nov 9 '11 at 15:54
does running sudo dpkg --configure -a help? – Ciaran Liedeman Nov 9 '11 at 15:58
You can try to set it to „Main server” and do an update, just to exclude the case that your repository is not up-to-date. If it does not help set it back, it eases the load on the main servers. – lgarzo Nov 9 '11 at 16:04
Changing to main server didn't help. it allowed dist-upgrade to run without any errors, but I still have the same situation when trying to install vim – croceldon Nov 9 '11 at 17:45
up vote 4 down vote accepted

You'll need to check your sources. I see that libruby1.8 is available through main while it seems that the newest version you have is: This probably means that you dist-upgrade failed or that you still need to update your sources.

$ apt-cache policy libruby1.8
  Version table:
 *** 0
        500 oneiric/main amd64 Packages
        100 /var/lib/dpkg/status
share|improve this answer
How do I update the sources? I've already tried doing the apt-get install update/upgrade... The dist-upgrade fails with the same error I posted in the original question. – croceldon Nov 9 '11 at 15:55
From which distribution are you upgrading? That should help to know if there's any known problem. I've checked the libruby1.8 package version in natty and looks like you're upgrading from an older distribution. – jcollado Nov 9 '11 at 16:51
I'm afraid you're getting over my head. I can't even remember what I've upgraded (I've done several upgrades on this little used installation). – croceldon Nov 9 '11 at 17:44
Looking at hardy and intrepid, I'd say that you're getting a version from hardy (you could still see that using apt-cache policy libruby1.8 as I did above anyway). The recommended upgrade path would be upgrade to the next LTS and later to the next following distro: 8.04 (LTS) -> 10.04 (LTS) -> 10.10 -> 11.04 -> 11.10. Those are probably too many upgrades, so I'd advice to backup your home directory and install oneiric 11.10 from scratch. – jcollado Nov 10 '11 at 5:20

The following worked for me:

run this

sudo apt-get update 

and then run

sudo apt-get install vim-gnome 
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.