3

So when I try to install just wine it goes without a problem, however it obviously does not install wine32 which is needed for the applications I want to run.

I've already added sudo dpkg --add-architecture i386

However when I try to sudo apt install wine32 I get these errors:

Building dependency tree       
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 libavcodec58 : Breaks: libavcodec58:i386 (!= 7:4.2.4-1ubuntu0.1)
 libavcodec58:i386 : Depends: libaom0:i386 (>= 1.0.0) but it is not going to be installed
                     Depends: libavutil56:i386 (= 7:4.3.1-5) but it is not going to be installed
                     Depends: libcairo2:i386 (>= 1.2.4) but it is not going to be installed
                     Depends: libcodec2-0.9:i386 (>= 0.9.2) but it is not going to be installed
                     Depends: libdav1d4:i386 (>= 0.2.1) but it is not installable
                     Depends: libglib2.0-0:i386 (>= 2.12.0) but it is not going to be installed
                     Depends: libgsm1:i386 (>= 1.0.18) but it is not going to be installed
                     Depends: libmp3lame0:i386 (>= 3.100) but it is not going to be installed
                     Depends: libopenjp2-7:i386 (>= 2.0.0) but it is not going to be installed
                     Depends: libopus0:i386 (>= 1.1) but it is not going to be installed
                     Depends: librsvg2-2:i386 (>= 2.14.4) but it is not going to be installed
                     Depends: libshine3:i386 (>= 3.1.0) but it is not going to be installed
                     Depends: libsnappy1v5:i386 (>= 1.1.8) but it is not going to be installed
                     Depends: libspeex1:i386 (>= 1.2~beta3-1) but it is not going to be installed
                     Depends: libswresample3:i386 (= 7:4.3.1-5) but it is not going to be installed
                     Depends: libtheora0:i386 (>= 1.0) but it is not going to be installed
                     Depends: libtwolame0:i386 (>= 0.3.10) but it is not going to be installed
                     Depends: libva2:i386 (>= 2.2.0) but it is not going to be installed
                     Depends: libvorbis0a:i386 (>= 1.1.2) but it is not going to be installed
                     Depends: libvorbisenc2:i386 (>= 1.1.2) but it is not going to be installed
                     Depends: libvpx6:i386 (>= 1.6.0) but it is not going to be installed
                     Depends: libwavpack1:i386 (>= 4.40.0) but it is not going to be installed
                     Depends: libwebp6:i386 (>= 0.5.1) but it is not going to be installed
                     Depends: libwebpmux3:i386 (>= 0.6.1-2+b1) but it is not going to be installed
                     Depends: libx264-160:i386 (>= 2:0.160.3011+gitcde9a93) but it is not installable
                     Depends: libx265-192:i386 (>= 3.2) but it is not installable
                     Depends: libxvidcore4:i386 (>= 1.2.2) but it is not going to be installed
                     Depends: libzvbi0:i386 (>= 0.2.35) but it is not going to be installed
                     Breaks: libavcodec58 (!= 7:4.3.1-5)
 wine32:i386 : Depends: libwine:i386 (= 5.0-3ubuntu1) but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages

After a deeper look it seems that there are 2 problems:

1) Some dependencies "break" each other

2) Many dependecies are required in a version that is just not available from Ubuntu 20.04

Can I somehow force wine32 install to install dependencies with the needed versions?

Sidenote: wine broke after an upgrade from Ubuntu 18.04 to 20.04, on 18.04 I somehow got it working just fine using add architecture and the winehq repository...

EDIT

repositories
Currently disabled (was enabled while I was trying to debug this)
https://download.opensuse.org/repositories/Emulators:/Wine:/Debian/xUbuntu_18.04/ (regular & source)
Currently enabled
https://dl.winehq.org/wine-builds/ubuntu/ (regular & source)

output of apt-cache policy wine32

wine32:i386:
  Installed: (none)
  Candidate: 5.0-3ubuntu1
  Version table:
     5.0-3ubuntu1 500
        500 http://archive.ubuntu.com/ubuntu focal/universe i386 Packages

output of grep -ir ^deb /etc/apt/ --include=*.list

/etc/apt/sources.list:deb http://archive.ubuntu.com/ubuntu focal main universe restricted multiverse
/etc/apt/sources.list:deb http://security.ubuntu.com/ubuntu/ focal-security restricted universe multiverse main
/etc/apt/sources.list:deb http://archive.ubuntu.com/ubuntu focal-updates restricted universe multiverse main
/etc/apt/sources.list:deb http://archive.ubuntu.com/ubuntu focal-backports restricted universe multiverse main
/etc/apt/sources.list:deb https://dl.winehq.org/wine-builds/ubuntu/ focal main
/etc/apt/sources.list:deb-src https://dl.winehq.org/wine-builds/ubuntu/ focal main

When I've disabled all those repositories and purge all wine and ran autoremove and clean and autoclean and apt update, then tried to sudo apt install wine32 the output is now:

The following packages have unmet dependencies:
 wine32:i386 : Depends: libwine:i386 (= 5.0-3ubuntu1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Output of apt-cache policy wine32 remains the same output of grep -ir ^deb /etc/apt/ --include=*.list is reduced by the removed repos.

EDIT 2:

apt-cache policy libwine:i386
libwine:i386:
  Installed: (none)
  Candidate: 5.0-3ubuntu1
  Version table:
     5.0-3ubuntu1 500
        500 http://archive.ubuntu.com/ubuntu focal/universe i386 Packages

dpkg -l | grep -i wine => no results

sudo apt-get install libwine:i386
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: libwine:i386 : Depends: libfaudio0:i386 (>= 19.06.07) but it is not going to be installed Depends: libglib2.0-0:i386 (>= 2.12.0) but it is not going to be installed Depends: libgphoto2-6:i386 (>= 2.5.10) but it is not going to be installed Depends: libgstreamer-plugins-base1.0-0:i386 (>= 1.0.0) but it is not going to be installed Depends: libgstreamer1.0-0:i386 (>= 1.4.0) but it is not going to be installed Depends: libxml2:i386 (>= 2.9.0) but it is not going to be installed Recommends: libcups2:i386 (>= 1.4.0) but it is not going to be installed Recommends: libgssapi-krb5-2:i386 (>= 1.6.dfsg.2) but it is not going to be installed Recommends: libkrb5-3:i386 (>= 1.6.dfsg.2) but it is not going to be installed Recommends: libsane:i386 (>= 1.0.24) but it is not going to be installed Recommends: libxslt1.1:i386 (>= 1.1.25) but it is not going to be installed Recommends: gstreamer1.0-plugins-good:i386 but it is not going to be installed E: Unable to correct problems, you have held broken packages.

jave.web
  • 420
  • Can't reproduce on fresh 20.04 LTS VM. What is the output of apt-cache policy wine32? Do you have any wine-related PPAs or third-party repositories in the system? What is the output of grep -ir ^deb /etc/apt/ --include=*.list? – N0rbert Dec 21 '20 at 18:59
  • @N0rbert I've tried to remove them purge everything in an attempt of clean install - but still having issues with libwine:i386 - I've added that to the edit too now – jave.web Dec 22 '20 at 03:03
  • Still can't reproduce even with WineHQ PPA. Please add output of apt-cache policy libwine:i386 and dpkg -l | grep -i wine, 'dpkg -l | grep ^ii -v'. Then try sudo apt-get install libwine:i386 and share error message. – N0rbert Dec 22 '20 at 06:19
  • It seems that you have some locally installed packages. Please install Aptitude with sudo apt-get install aptitude and then add output of aptitude search ~o command. Alongside with dpkg -l | grep -v ^ii . – N0rbert Dec 22 '20 at 15:38
  • @N0rbert outputs of those are tooo big for adding as edit, so I've put them on this external link: https://ideone.com/4CDGUg – jave.web Dec 22 '20 at 15:48
  • Make sure that dl.winehq.org repository is removed. Then try installing all new dependencies by sudo dpkg --add-architecture i386, sudo aptitude update, sudo aptitude dist-upgrade and finally sudo aptitude install wine32. – N0rbert Dec 22 '20 at 16:35
  • @N0rbert yep I removed all of the extra repositories - install of wine32 selected "wine32:i386" instead of the virtual package "wine32" then asked: The following actions will resolve these dependencies: Keep the following packages at their current version: [list 41 dependencies] and Leave the following dependencies unresolved: 42) libgstreamer-plugins-base1.0-0:i386 recommends gstreamer1.0-plugins-base:i386 43) libsasl2-2:i386 recommends libsasl2-modules:i386 (>= 2.1.27+dfsg-2) I could choose Accept this solution? [Y/n/q/?] so I chose Y => No packages will be installed, upg.... – jave.web Dec 22 '20 at 21:28
  • You have some problem with obsolete packages, I think. Please add such long commands outputs like sudo aptitude install wine32 to the question or to pastebin. Run aptitude why-not wine32 and show its output. Next step will be removal of unnecessary packages from list generated by aptitude search ~o . – N0rbert Dec 23 '20 at 07:09
  • @N0rbert yep I have a similar feeling I just don't understand why there is not a simple way to just force the correct packages :/ ... here are outputs of those commands in order you wrote them: https://pastebin.com/x9cCrgzk – jave.web Dec 23 '20 at 07:57

2 Answers2

3

The problem was caused by three locally installed packages which are PHP-related and came from deb.sury.org repository.

So the fix was the following:

sudo apt-get install libpcre2-8-0=10.34-7
sudo apt-get install libssl1.1=1.1.1f-1ubuntu2.1
sudo apt-get install libssl1.1:i386=1.1.1f-1ubuntu2.1

sudo aptitude install wine32


If you want to remove all deb.sury.org packages - carefully use one-liner like

sudo apt-get purge $(dpkg -l | grep deb.sury.org | awk '{print $2}')

And then install PHP back with:

sudo apt-get install php-bcmath php-bz2 php-common php-curl php-intl \
php-json php-mbstring php-mysql php-opcache php-readline php-recode \
php-tidy php-xmlrpc
N0rbert
  • 99,918
  • If you want to clear more - !danger!, it will remove some of your old PHP versions - from the deb.sury.org repository aka ppa:ondrej/php refer to this Q/A https://askubuntu.com/questions/529988/replace-deb-sury-org-php-with-original – jave.web Dec 23 '20 at 08:51
0

I had the same problem and it was related to conflict package Nginx. If you are using Nginx try removing Nginx, install wine32 and then reinstall nginx. (Ubuntu 20.04, 20.04 LTS)