Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ubuntu-20.04] Unable to install wine32:i386 / issues with i386 arch support in apt #4589

Closed
1 of 7 tasks
ethteck opened this issue Nov 25, 2021 · 78 comments
Closed
1 of 7 tasks
Assignees
Labels
external investigate Collect additional information, like space on disk, other tool incompatibilities etc. OS: Ubuntu

Comments

@ethteck
Copy link

ethteck commented Nov 25, 2021

Description

We noticed in our project that somewhere in between 20211114.1 and 20211122.1, apt behavior changed when adding the i386 arch. We use this to install wine for running 32-bit processes. One of our tests is failing now because the version of wine installed is for 64-bit processes.

Additionally, you can see when you compare the two runs that the packages installed greatly differ despite being pretty much identical repo states (and identical runner scripts).

Virtual environments affected

  • Ubuntu 18.04
  • Ubuntu 20.04
  • macOS 10.15
  • macOS 11
  • Windows Server 2016
  • Windows Server 2019
  • Windows Server 2022

Image version and build link

https:/decompme/decomp.me/runs/4321547477

Is it regression?

20211114.1

Expected behavior

Apt installs :i386 versions of things so the correct wine is installed

Actual behavior

Apt is not installing these

Repro steps

Create an ubuntu-latest action that runs

sudo dpkg --add-architecture i386
sudo apt update
sudo apt install wine

And then attempt to execute a 32-bit windows executable

@dibir-magomedsaygitov dibir-magomedsaygitov added OS: Ubuntu investigate Collect additional information, like space on disk, other tool incompatibilities etc. and removed needs triage labels Nov 25, 2021
@dibir-magomedsaygitov
Copy link
Contributor

Hello @ethteck. Thank you for your report. We will take a look.

@dibir-magomedsaygitov
Copy link
Contributor

@ethteck could you please try to apply workaround described here

@dibir-magomedsaygitov dibir-magomedsaygitov self-assigned this Nov 25, 2021
@ethteck
Copy link
Author

ethteck commented Nov 25, 2021

Hi, thanks for the swift reply! Unfortunately, that doesn't seem to be helping. "wine" and "wine64" install, but "wine" is unable to run 32-bit binaries.

If I try to install "wine32" (which I get warnings that I should do), I get apt errors:
https:/decompme/decomp.me/runs/4323785244?check_suite_focus=true

The following packages have unmet dependencies:
 wine32:i386 : Depends: libwine:i386 (= 5.0-3ubuntu1) but it is not going to be installed

@ethteck
Copy link
Author

ethteck commented Nov 25, 2021

If I understood what change in the new version caused the regression, I could maybe manually do some repository management to fix it, but I'm a bit lost as to what change could have caused this..

@actions actions deleted a comment Nov 25, 2021
@actions actions deleted a comment Nov 25, 2021
@actions actions deleted a comment Nov 25, 2021
@dibir-magomedsaygitov
Copy link
Contributor

@ethteck I've tried to reproduce the issue, but my run was successful (link the run)

@ethteck
Copy link
Author

ethteck commented Nov 25, 2021

Installing wine is working for us, but it appears to not have 32 bit support because of errors we get in our tests. I'll make a sample repo tomorrow that simply downloads wine and tries to execute a 32-bit executable through wine, to easier demonstrate what's going on.

And thank you for your time and effort so far, looking into this!

@ensiform
Copy link

ensiform commented Nov 25, 2021

Having a similar issue to this mysteriously failing on libglib2.0-dev:i386 and libsdl2-dev:i386 on my project here:

https:/etfdevs/ETe/runs/4326926427?check_suite_focus=true

Attempting to add the listed packages only further adds more package complaints https:/etfdevs/ETe/runs/4327104370?check_suite_focus=true

When it built fine the previously action with no issues on packages a couple weeks ago since last action ran.

x86_64 seems to pass/build just fine with same non i386 libs as well.

Can start separate issue if necessary.

@Sam-Sundar
Copy link

Sam-Sundar commented Nov 25, 2021

Same issue for us too, some recent change to runners broke apt adding i386 architecture.

Reading package lists...
Building dependency tree...
Reading state information...
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:
 winehq-stable : Depends: wine-stable (= 6.0.2~focal-1)
E: Unable to correct problems, you have held broken packages.

Also when trying to install wine32 is throwing much more dependency issues.

Maybe this Ubuntu update broke apt ? Since it's the same timeframe we started to face issues with apt

@actions actions deleted a comment Nov 26, 2021
@ethteck
Copy link
Author

ethteck commented Nov 26, 2021

Glad to see this isn't just me with this issue. I made a test repo that just tries to install wine after adding the i386 arch and executing a small win32 console application:

https:/ethteck/github-wine-test

As you can see, it's acting like wine32 is not installed and suggesting I run apt-get install wine32, but this does not work as I get similar errors to those posting above

Link to build that tries to install wine32 instead of wine: https:/ethteck/github-wine-test/runs/4337303248?check_suite_focus=true

@smudrak
Copy link

smudrak commented Nov 26, 2021

Adding
sudo apt install -y --allow-downgrades libpcre2-8-0=10.34-7
before wine32 install seems to fix the broken dependency. If you do not need packages removed by this downgrade.

@Sam-Sundar
Copy link

Hi @smudrak,

Getting this error if we try to install libpcre2-8-0

Reading package lists...
Building dependency tree...
Reading state information...
E: Version '10.34-7' for 'libpcre2-8-0' was not found
Error: Process completed with exit code 100.

@smudrak
Copy link

smudrak commented Nov 27, 2021

Hmmm, that's weird, 10.34-7 is the official version of this package in 20.04LTS. We cross-compile our project using mxe, so maybe it is loaded from the depository we add. This is the whole set of commands we use to setup our runner.

sudo dpkg --add-architecture i386
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 86B72ED9
sudo add-apt-repository 'deb [arch=amd64] https://mirror.mxe.cc/repos/apt focal main'
sudo apt -qq update
sudo apt install -y --allow-downgrades libpcre2-8-0=10.34-7
sudo apt install -y wine32

@Sam-Sundar
Copy link

Hey @smudrak ,

Wine is now installing. Thanks much.

@jobackman
Copy link

Can also confirm that @smudrak's workaround seems to have solved it for me as well

@ethteck
Copy link
Author

ethteck commented Nov 29, 2021

I may be missing something, but the above suggestion hasn't worked for me unfortunately. When I try to install wine32, I get

Package wine32 is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  libwine``` and installing just "wine" does not install the 32 bit version, as it did on the older version of the environment when the i386 arch was added

@ethteck
Copy link
Author

ethteck commented Nov 29, 2021

My apologies - in my yml editing, I mistakenly deleted the most important command: adding the i386 arch. This does indeed work! Thank you @smudrak for the workaround!

It is a bit unfortunate to have to add a repository and do the install of a specific depdenency with the allow downgrades command, however. Is it possible to make this use case more user friendly in the future?

@dibir-magomedsaygitov
Copy link
Contributor

Hello @ethteck. Thank you for the provided information. Since we don't install 32bit packages on our images we don't have plans to enable multiarch. I'm going to close this issue for now. Feel free to contact us in case of any questions.

vincentkfu added a commit to vincentkfu/fio that referenced this issue May 15, 2023
The GitHub Actions image has had a longstanding problem with the
dependencies required for 32-bit builds. The current work around no
longer fixes the issue. Stop testing 32-bit builds to avoid false
positive failures with our CI testing.

We can re-enable 32-bit builds when this issue is fixed upstream.

Details: actions/runner-images#4589

Signed-off-by: Vincent Fu <[email protected]>
@mboudreau
Copy link

I'm getting the same issues, has anyone figured out a workaround? Thanks.

@ValdikSS
Copy link

Current working solution for ubuntu-20.04 is:

sudo dpkg --add-architecture i386
sudo dpkg -l | awk '/ii  lib.*deb.sury.org/ {gsub(/:.*/, s, $2); print $2}' | xargs apt show -a | awk '/Package:/ {p=$2} /APT-Sources: .*focal\/main/ {print p"/focal"}' | sudo xargs eatmydata apt install --allow-downgrades
sudo apt update
sudo DEBIAN_FRONTEND=noninteractive eatmydata apt install -y --no-install-recommends wine-stable wine32

Saves 2 minutes compared to @burner1024 action.

My method still works, @mboudreau.

@mboudreau
Copy link

@ValdikSS Any solutions for ubuntu 22.04?

@ValdikSS
Copy link

@ValdikSS Any solutions for ubuntu 22.04?

Try this:

sudo eatmydata apt-get install ppa-purge
sudo eatmydata ppa-purge -y ppa:ubuntu-toolchain-r/test

sudo dpkg --add-architecture i386
sudo apt update
sudo DEBIAN_FRONTEND=noninteractive eatmydata apt install -y --no-install-recommends wine-stable wine32

@mboudreau
Copy link

mboudreau commented May 17, 2023

That didn't fully work for me @ValdikSS (thanks btw), but the ppa-purge did fix many issues: wine did install, but I was still getting some issues while building (lack of dependencies and mono install).

These steps worked for me:

- run: sudo apt-get install ppa-purge && sudo ppa-purge -y ppa:ubuntu-toolchain-r/test
# Install Wine
- run: sudo dpkg --add-architecture i386
- run: sudo mkdir -pm755 /etc/apt/keyrings && sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
- run: sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/jammy/winehq-jammy.sources
- run: sudo apt-get update
- run: sudo apt install --install-recommends winehq-stable
# Install mono
- run: sudo mkdir -p /opt/wine/mono && sudo wget "https://dl.winehq.org/wine/wine-mono/8.0.0/wine-mono-8.0.0-x86.tar.xz" -P /opt/wine/mono && sudo tar -xf /opt/wine/mono/wine-mono-8.0.0-x86.tar.xz -C /opt/wine/mono && sudo rm /opt/wine/mono/wine-mono-8.0.0-x86.tar.xz

@falkTX
Copy link

falkTX commented May 17, 2023

I was able to get things working with this:

sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo dpkg --add-architecture i386
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades binutils-mingw-w64-x86-64 g++-mingw-w64-x86-64 libc6:i386 libgcc-s1:i386 libstdc++6:i386 mingw-w64 wine-stable

That installs both mingw and wine, handy for cross-compilation
The trick is to use --allow-downgrades in combination with the basic libs libc6:i386 libgcc-s1:i386 libstdc++6:i386, then add the other stuff you need on the same line.

@ethteck
Copy link
Author

ethteck commented May 18, 2023

Thanks @falkTX - for us, we don't need mingw, so I was able to remove the binutils / mingw stuff, and the solution became quite concise compared to what we were doing before. I also used wine instead of wine-stable - not sure if that makes any real difference other than maybe just which version is installed.

sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo dpkg --add-architecture i386
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades libc6:i386 libgcc-s1:i386 libstdc++6:i386 wine

Stay tuned for next time when things inevitably break out from under us again! 📺

vincentkfu added a commit to vincentkfu/fio that referenced this issue May 18, 2023
vincentkfu added a commit to vincentkfu/fio that referenced this issue May 18, 2023
Fix the dependency install problem for 32-bit builds by explicitly
installing libc6:i386 and libgcc-s1:i386 as mentioned in the link below.

actions/runner-images#4589 (comment)

Deleting microsoft-prod.list and adding --allow-downgrades were not
needed for our use case.

Signed-off-by: Vincent Fu <[email protected]>
axboe pushed a commit to axboe/fio that referenced this issue May 18, 2023
Fix the dependency install problem for 32-bit builds by explicitly
installing libc6:i386 and libgcc-s1:i386 as mentioned in the link below.

actions/runner-images#4589 (comment)

Deleting microsoft-prod.list and adding --allow-downgrades were not
needed for our use case.

Signed-off-by: Vincent Fu <[email protected]>
JuliaSprenger added a commit to JuliaSprenger/python-neo that referenced this issue May 25, 2023
@MdJeweleIslam
Copy link

MdJeweleIslam commented Jun 13, 2023

sudo dpkg --add-architecture i386
sudo apt update
sudo apt install wine32

Its working for me.

vthib added a commit to vthib/boreal that referenced this issue Jun 17, 2023
See this discussion: actions/runner-images#4589

Something changed in the github image which broke this installation :/
vthib added a commit to vthib/boreal that referenced this issue Jun 17, 2023
See this discussion: actions/runner-images#4589

Something changed in the github image which broke this installation :/
@Xses-1
Copy link

Xses-1 commented May 11, 2024

I am getting something similar still:

# sudo apt install wine32
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Starting pkgProblemResolver with broken count: 1
Starting 2 pkgProblemResolver with broken count: 1
Investigating (0) libfaudio0:i386 < none -> 22.02-1 @un puN Ib >
Broken libfaudio0:i386 Depends on libsdl2-2.0-0:i386 < none | 2.0.20+dfsg-2ubuntu1.22.04.1 @un uH > (>= 2.0.16)
  Considering libsdl2-2.0-0:i386 0 as a solution to libfaudio0:i386 0
  Considering libsdl2-2.0-0:i386 0 as a solution to libfaudio0:i386 0
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:
 libfaudio0:i386 : Depends: libsdl2-2.0-0:i386 (>= 2.0.16) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

@Xses-1
Copy link

Xses-1 commented May 11, 2024

When I run sudo apt install libsdl2-2.0-0:i386 it throws a lot of nonsense (I am on KDE Neon):

The following packages have unmet dependencies:
 libsdl2-2.0-0:i386 : Depends: libdecor-0-0:i386 (>= 0.1.0) but it is not going to be installed
 neon-desktop : Depends: kaccounts-providers but it is not going to be installed
                Depends: kinfocenter but it is not going to be installed
                Depends: kio-extras but it is not going to be installed
                Depends: kwin-wayland but it is not going to be installed
                Depends: kwin-x11 but it is not going to be installed
                Depends: powerdevil but it is not going to be installed
                Depends: sddm-theme-breeze
                Recommends: dolphin but it is not going to be installed
                Recommends: dolphin-plugins but it is not going to be installed
                Recommends: gwenview but it is not going to be installed
                Recommends: kde-spectacle but it is not going to be installed
                Recommends: kdeconnect but it is not going to be installed
                Recommends: kdeplasma-addons but it is not going to be installed
                Recommends: kdialog but it is not going to be installed
                Recommends: kio-gdrive but it is not going to be installed
                Recommends: kio-gdrive-5 but it is not going to be installed
                Recommends: konsole but it is not going to be installed
                Recommends: kscreen but it is not going to be installed
                Recommends: kwrite but it is not going to be installed
                Recommends: okular but it is not going to be installed
                Recommends: plasma-browser-integration but it is not going to be installed
                Recommends: plasma-nm but it is not going to be installed
                Recommends: plasma-systemmonitor but it is not going to be installed
                Recommends: plasma-workspace-wayland
                Recommends: snapd but it is not going to be installed
                Recommends: vim
 plasma-desktop : Depends: plasma-workspace (>= 4:6.0.4) but it is not going to be installed
                  Depends: libsdl2-2.0-0 (>= 2.28.5+dfsg) but it is not installable
                  Recommends: kde-style-oxygen-qt6 but it is not installable
                  Recommends: kinfocenter but it is not going to be installed
                  Recommends: kio-extras but it is not going to be installed
                  Recommends: kscreen but it is not going to be installed
                  Recommends: kwin-wayland but it is not going to be installed or
                              kwin-x11 but it is not going to be installed
                  Recommends: powerdevil but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.

@bombseb
Copy link

bombseb commented Jun 20, 2024

Hi

Same as Xses-1 (I'm on KDE Neon too)

@Xses-1
Copy link

Xses-1 commented Jun 21, 2024

@bombseb I am pretty sure it's Neon's fault. This distro is just broken sometimes and they just messed up the dependencies.

@bombseb
Copy link

bombseb commented Jun 22, 2024

@Xses-1 Yes, it's not the first time I've had dependency issues with this distribution. Two weeks ago, I had to reinstall everything due to a dependency issue with Pipewire.

@Xses-1
Copy link

Xses-1 commented Jun 22, 2024

Why there's no clean Ubuntu-wit-Plasma kinda distro? Kubuntu is too close to Ubuntu so you get Sanps, telemetry, broken kernels, etc. While Neon is just a Beta testing platform for KDE, so it's always broken.

@messmerd
Copy link

I was able to install Wine from WineHQ after running this:

# Remove ppa:ondrej/php since it breaks i386 packages -- https:/oerdnj/deb.sury.org/issues/1745
sudo add-apt-repository ppa:ondrej/php
sudo apt-get install --yes ppa-purge
sudo ppa-purge -y ppa:ondrej/php

@Xses-1
Copy link

Xses-1 commented Jun 22, 2024

@messmerd I followed your instructions and the instructions from winehq including the supposed fix for the libplopper on kde neon and I got to the exact same broken dependencies problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
external investigate Collect additional information, like space on disk, other tool incompatibilities etc. OS: Ubuntu
Projects
None yet
Development

No branches or pull requests