1

(EDIT: this question was suggested to be answered with this one but, although the problem is the same one, I see the given solution in this post better than the other one (more efficient)! So please keep this question, or move the solution to the other one, so other users can know this solution!)

For some unknwon reason, wine stuck when loading any Windows program. So I uninstalled it for reinstalling it again. I have Ubuntu 18.04.5 LTS.

When I try to reinstall it, following the winehq.org steps, in the last step, it says:

 winehq-stable : Depends: wine-stable (= 5.0.2~bionic)
E: Unable to correct problems, you have held broken packages.

I've tried to install manually the dependencies, but arrived to a lot of packages that "won't be installed". Of course, googled it. Tried, then:

sudo dpkg --configure -a
sudo apt-get install -f
sudo apt-get autoremove
sudo apt-get autoclean
sudo apt-get update

Tried as well unholding two packages that have anything to do with this, but nothing.

Then:

sudo aptitude -f install winehq-stable

I'm grateful because aptitude made an effort to solve this, but all the solutions that it proposes include:

     Keep the following packages in the current version:
2)     wine-stable [not installed]                          
3)     wine-stable-i386:i386 [not installed]                
4)     winehq-stable [not installed]   

I don't know how to say it that I want to update those from "not installed" to any that requires to be installed.

I've tried, as well, fixing broken packages through Synaptics (and said that succeeded), and some other solutions I've found on the Internet that I can't remember now, but I'll tell you if suggested.

The package is not installed now (every attemp to purge or something won't work because this).

Any ideas? I want to believe this can be solved without reinstalling the whole OS.

3
  • 2
    Did it give you any error messages when you setup the wine repositories? What is the output of when you run sudo apt update?
    – Terrance
    Sep 13 '20 at 1:14
  • 2
    Does this answer your question? can't install wine on ubuntu (actually lubuntu) 18.04
    – N0rbert
    Sep 13 '20 at 8:05
  • Thank you very much to both! the apt update said nothing (the errors came just when trying to install), and N0rbert, your post revealed what was happening (not knowing what is going on is always 50% of the frustration to me): Ubuntu 18.04 nor WineHQ have the package libfaudio0, available since Ubuntu 19.10. I didn't update to Ubuntu 20.04 yet because I prefer Ubuntu to offer the upgrade by itself, but it hasn't done it yet.
    – Bross
    Sep 13 '20 at 11:35
1

You need to install libfaudio0 as well, in your Ubuntu 18.04 installation using

sudo add-apt-repository ppa:cybermax-dexter/sdl2-backport

You may also need to enable 32 bit architecture, if it isn't enabled using

sudo dpkg --add-architecture i386

So for the whole installation process:

sudo dpkg --add-architecture i386
wget -nc https://dl.winehq.org/wine-builds/winehq.key; sudo apt-key add winehq.key
sudo apt-add-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ bionic main'
sudo add-apt-repository ppa:cybermax-dexter/sdl2-backport
sudo apt update && sudo apt install --install-recommends winehq-stable
1
  • Thank you very much! 🙌 Finally installed and working! Incredibly efficient solution 👏🎆
    – Bross
    Sep 13 '20 at 11:29

Your Answer

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

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