2

I am in elementary OS Freya.

sudo apt-get install wine
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 wine : Depends: wine1.6 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

And:

 sudo apt-get install playonlinux
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Some packages could not be installed. This may mean that you have
    requested an impossible situation or if you are using the unstable
    distribution that some required packages have not yet been created
    or been moved out of Incoming.
    The following information may help to resolve the situation:

    The following packages have unmet dependencies:
     playonlinux : Depends: wine or
                            wine-unstable but it is not installable
    E: Unable to correct problems, you have held broken packages.

While all PPAs are disabled and Ubuntu repos are enabled:

enter image description here

enter image description here

Otherwise there isn't any problem with the packages:

sudo apt-get -f install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

After following instructions from askubuntu,

  sudo apt-get -u dist-upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

So, no fail here.

But the initial error persists in terminal.

What happens in Synaptic is different! When trying to install playonlinux the packages to be removed included all my system so to speak. That would have completely broken the system. It is too long a list to post here.

When trying to install wine, it seems possible enter image description here

but this is contradicted by the terminal output posted above for sudo apt-get install wine, and all this looks fishy to me.


UPDATE

Trying to install wine in Synaptic, it does not work in fact: once selected to be installed, the wine package is marked as broken and some unmentioned packages are signaled as broken.

enter image description here


How to identify the broken packages? Is it possible they being signaled as broken to be an error?

  • You could try running sudo dpkg --add-architecture i386, then sudo apt-get update; that might allow apt-get install wine to work (if i386 isn't set up as a foreign architecture by default on elementary OS). – Stephen Kitt Jun 10 '15 at 9:47
  • @StephenKitt - after doing that, the same output for sudo apt-get install wine. What should I think about the contradiction considering wine between synaptic and apt-get install? Shouldn't syaptic give the same as apt-get? Could installing wine in synaptic be safe? Are those three packages to be removed essential to the system? – user32012 Jun 10 '15 at 9:50
  • Elementary OS is NOT Ubuntu - it may be derived from Ubuntu but it is its own Distro... – Thomas Ward Jun 10 '15 at 10:48
  • @ThomasW. - And that is why I am posting here and not on askubuntu. On the other hand, my problem is related to Ubuntu sources, used by eOS and all ubuntu-based "distros". – user32012 Jun 10 '15 at 11:10
  • @cipricus Indeed, I couldn't see your Synaptic screenshot but it confirms i386 was already set up as a foreign architecture. The packages it's suggesting you remove aren't all that important, you probably won't miss them; I'd go ahead and install with Synaptic. – Stephen Kitt Jun 10 '15 at 11:57
0

The main idea is to use aptitude and its larger options.

The answer follows this one on ubuntuforums.

  • Made /etc/apt/sources.list support multiarch by adding [arch=amd64,i386] to the deb-line:

deb [arch=amd64,i386] http://fr.archive.ubuntu.com/ubuntu/ trusty universe

sudo add-apt-repository ppa:ubuntu-wine/ppa
sudo dpkg --add-architecture i386
sudo apt-get update

Update of the database now showed separate amd64 and i386 repos to be loaded.

Next I switched to aptitude, because of the more sophisticated dependency-solver:

sudo apt-get install aptitude

sudo aptitude --full-resolver -f install wine1.7

Full details: http://pastebin.com/Z9Ww11SU

What I did in short:

  • aptitude suggested a solution where wine1.7 would not be installed, that was selected first (20)
  • This solution was rejected with r 20 -- it was a bit complicated for me, I just replicated the commands from the other answer: first selected 20 instead of YES or NO; then r 20 (rejecting the removal of Wine 1.7);
  • then n (It seems that unless you choose Y, YES, aptitude --full-resolver gives you new options after each decision; I guess in this case was NO because it said "dependencies unresolved" for Wine);
  • the next step provided the good solution: to install Wine and to downgrade 14 packages:

ibasn1-8-heimdal libgphoto2-6 libgphoto2-port10 libgssapi3-heimdal libhcrypto4-heimdal libheimbase1-heimdal libheimntlm0-heimdal libhx509-5-heimdal libkrb5-26-heimdal liblcms2-2 libroken18-heimdal libsane libsane-common libwind0-heimdal

  • So, last one was Y YES, and Wine 1.7 was installed.

  • After that, the installation of playonlinux went without problems:

The following NEW packages will be installed:
  libwxgtk-media2.8-0{a} mesa-utils{a} playonlinux python-wxgtk2.8{a} python-wxversion{a} 
0 packages upgraded, 5 newly installed, 0 to remove and 0 not upgraded.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy