Wine-staging fails to install on 18.04

24,679

Solution 1

I followed the instructions found here to download the missing libfaudio:i386.

Ubuntu 18.04:

wget https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/Release.key

sudo apt-key add Release.key

Add the repository:

sudo apt-add-repository 'deb https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/ ./'

Then update:

sudo apt update

Solution 2

I had similar problem, I went down a few different rabbit-holes so thought it might help others if I detail my solution. I am not particularly au fait with the apt packaging process or wine so I will list out everything that I went through from upgrading from wine3.0 to wine5.0 on ubuntu 18.04.4 LTS.

  1. Purge all from APT!
sudo apt-get purge *wine*
  1. Check that there's no snaps installed too (for some reason i had this - not sure if it would impact so i assumed best to remove)
sudo snap remove wine
sudo snap update wine-platform-*
  1. Remove the PPA official repos (they changed how they packaged this). We need to dig inside /etc/apt
grep -Ril "wine" /etc/apt

If you get any matches comment them out or delete the keys, we will fully re-add later.

  1. Enable 32-bit & add new repo (check here for other ubuntu versions)
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 apt update
sudo apt upgrade
sudo apt --fix-broken install
sudo apt autoremove --purge
sudo apt upgrade
  1. Let's get the libfaudio & libasound2 which are the broken repos:
wget https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/Release.key
sudo apt-key add Release.key
sudo apt-add-repository 'deb https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/ ./'
sudo apt update
sudo apt install libfaudio0 libasound2-plugins:i386 -y
  1. Now we can install wine 5.0 as normal!
sudo apt install --install-recommends winehq-stable -y
Share:
24,679
Oded Sayar
Author by

Oded Sayar

Updated on September 18, 2022

Comments

  • Oded Sayar
    Oded Sayar over 1 year

    I'm trying to run games through Lutris and followed their wiki on installing wine-staging.

    When running:

    $ sudo apt install --install-recommends winehq-staging
    

    I get the error they predict, but then when running:

    $ sudo apt install --install-recommends winehq-staging wine-staging wine-staging-i386
    

    I still have the unmet dependencies error (output below).

    Could anyone direct me to a solution?

    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-staging : Depends: wine-staging-amd64 (= 4.13~bionic) but it is not going to be installed
     wine-staging-i386:i386 : Depends: libfaudio0:i386 but it is not installable
                              Recommends: libcairo2:i386 but it is not going to be installed
                              Recommends: libcapi20-3:i386 but it is not going to be installed
                              Recommends: libcups2:i386 but it is not going to be installed
                              Recommends: libglu1-mesa:i386 but it is not going to be installed or
                                          libglu1:i386
                              Recommends: libgsm1:i386 but it is not going to be installed
                              Recommends: libgssapi-krb5-2:i386 but it is not going to be installed
                              Recommends: libgtk-3-0:i386 but it is not going to be installed
                              Recommends: libkrb5-3:i386 but it is not going to be installed
                              Recommends: libodbc1:i386 but it is not going to be installed
                              Recommends: libosmesa6:i386 but it is not going to be installed
                              Recommends: libpcap0.8:i386 but it is not going to be installed
                              Recommends: libsane:i386 or
                                      libsane1:i386 but it is not going to be installed
                              Recommends: libv4l-0:i386 but it is not going to be installed
                              Recommends: libva-drm2:i386 but it is not going to be installed or
                                          libva-drm1:i386 but it is not installable
                              Recommends: libva-x11-2:i386 but it is not going to be installed or
                                          libva-x11-1:i386 but it is not installable
                              Recommends: libva2:i386 but it is not going to be installed or
                                          libva1:i386 but it is not installable
                              Recommends: libxcomposite1:i386 but it is not going to be installed
                              Recommends: libxslt1.1:i386 but it is not going to be installed
    E: Unable to correct problems, you have held broken packages.
    
  • Oded Sayar
    Oded Sayar almost 5 years
    remove: E: Unable to locate package winehq.key
  • Oded Sayar
    Oded Sayar almost 5 years
    It does seem to work if I replace wine-staging with wine-stable, but I figure staging is better for running games
  • Kristopher Ives
    Kristopher Ives almost 5 years
    You are running the wrong commands and trying to pass a file as a package nane
  • Byte Commander
    Byte Commander almost 5 years
    Always quote 'wine*' or escape wine\* package globs - otherwise they will be expanded by the shell as file globs, if you have any matching files in your current directory. That's likely what happened in @OdedSayar 's case. I'm editing your command.
  • Scott
    Scott over 4 years
    I tried using the repos in the other answers (the ppa:cybermax-dexter/sdl2-backport repo) and it horribly broke things. It wouldn't install because it conflicted with libfaudio (vs. libfaudio0), and no amount of shuffling helped. While I didn't add the repo above directly, I did download the libfaudio i386 and amd64 manually, and then wine-staging finally installed correctly!
  • Baku9
    Baku9 over 4 years
    While attempting to set up Wine for Lutris per this page, I kept running into unmet dependency issues, despite their solution for that exact issue. Your answer actually resolved the problem. Thank you!
  • Sjoerd de Wit
    Sjoerd de Wit about 4 years
    Just step 5 and 6 was enough to fix the issue for me
  • Miguel
    Miguel about 4 years
    For me, all unmet dependencies trace back to libpulse0:i386; this prevents installing the packages in the last line in your step 5. Any ideas?
  • Ufos
    Ufos about 4 years
    only step 5 is needed