Unable to uninstall wine in Ubuntu 18.04

26,268

Solution 1

You seem to have installed wine's development version (a.k.a. beta) which can be unstable sometimes. To remove wine, run:

sudo apt autoremove wine-devel wine-devel-amd64 wine-devel-i386 winehq-devel winetricks

I'll recommend you to install wine-stable to have a wine with minimal bugs. To install it run:

sudo apt install wine-stable

Solution 2

You can uninstall all dependencies related to wine

sudo apt-get remove --autoremove wine-*
Share:
26,268

Related videos on Youtube

Sachin Naregal
Author by

Sachin Naregal

Updated on September 18, 2022

Comments

  • Sachin Naregal
    Sachin Naregal over 1 year

    I am using Ubuntu 18.04 and recently I have installed wine and it was not able to find the .dll files so I ran the command sudo apt-get remove winehq it showed that the wine has been uninstalled but when I type which wine I am getting the output /usr/bin/wine it seems it hasn't been uninstalled completely and when I try sudo apt-get purge wine* I am getting the following errors

    E: Unable to locate package winehq.key
    E: Couldn't find any package by glob 'winehq.key'
    E: Couldn't find any package by regex 'winehq.key'
    

    Output of apt list --installed | grep wine:

    WARNING: apt does not have a stable CLI interface. Use with caution in scripts. 
    wine-devel/bionic,now 4.0~rc3~bionic amd64 [installed,automatic] 
    wine-devel-amd64/bionic,now 4.0~rc3~bionic amd64 [installed,automatic] 
    wine-devel-i386/bionic,now 4.0~rc3~bionic i386 [installed,automatic] 
    winehq-devel/bionic,now 4.0~rc3~bionic amd64 [installed] winetricks/bionic,bionic,now 0.0+20180217-1 all [installed]
    

    What am I doing wrong and how to complete remove everying that is related to wine and install install it properly

    • George Udosen
      George Udosen over 5 years
      Please run sudo dpkg --configure -a
    • user535733
      user535733 over 5 years
      Please explain clearly all the different ways you used to install Wine, including any failed attempts.
  • Max Svid
    Max Svid about 4 years
    worked for me on ubuntu 18.04
  • Delio M.
    Delio M. over 3 years
    For me too, on Ubuntu 20.04, and unlike the solution proposed in the accepted answer.