Score:3

Unable to install wine-staging

cn flag

I'm trying out Linux for the first time and trying to install Wine to play my games but I'm getting errors and I don't know how to fix :( please can anyone help me, I don't want to go back to windows

$ sudo apt-get install wine-staging
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: libc6 (>= 2.34) but 2.31-0ubuntu9.2 is to be installed
                Depends: wine-staging-i386 (= 7.1~impish-1)
                Depends: wine-staging-amd64 (= 7.1~impish-1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

and if I try typing:

$ sudo apt-get install wine-staging-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.
 wine-staging-i386:i386 : Depends: libc6:i386 (>= 2.34) but 2.31-0ubuntu9.2 is to be installed
                          Depends: libldap-2.5-0:i386 (>= 2.5.4) but it is not installable
                          Depends: libvkd3d1:i386 (>= 1.2~impish-1) but it is not going to be installed
                          Recommends: libcairo2: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: libgtk-3-0: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: libsdl2-2.0-0: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: libxcursor1:i386 but it is not going to be installed
                          Recommends: libxfixes3:i386 but it is not going to be installed
                          Recommends: libxi6:i386 but it is not going to be installed
                          Recommends: libxinerama1:i386 but it is not going to be installed
                          Recommends: libxrandr2:i386 but it is not going to be installed
                          Recommends: libxrender1:i386 but it is not going to be installed
                          Recommends: libxxf86vm1:i386 but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Can anyone help me to fix everyone online says to use the command sudo apt-get install but it doesn't work and I don't know how to fix this.

EDIT: I'm using ubuntu 20.4 and there's no errors doing updates or upgrades

N0rbert avatar
zw flag
What is your Ubuntu version? Which guide do you follow? Do you have any errors on `sudo apt-get update`?
cn flag
hi thank very much for the comment i updated my answer im using 20.4 and no erors thanks
Score:4
zw flag

You should know that codename of Ubuntu 20.04 LTS is focal, not impish. The latter is the codename for Ubuntu 21.10, which is not your version.

So you have to open the terminal and use the following commands:

sudo add-apt-repository -r -n 'deb https://dl.winehq.org/wine-builds/ubuntu/ impish main'

sudo dpkg --add-architecture i386 
cd /tmp
wget -nc https://dl.winehq.org/wine-builds/winehq.key
sudo apt-key add winehq.key

sudo add-apt-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ focal main'
sudo apt-get update
sudo apt-get install winehq-stable

Also, you may be interested in the installation of PlayOnLinux utility by sudo apt-get install playonlinux to install windows Games and applications using prepared and tested scripts/wizards.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.