2

I'm new to Ubuntu and tried to install wine earlier. I decided I didn't want to continue with the install though, so I tried to uninstall it using

sudo apt-get remove wine --purge

but whenever I open the terminal and type

wine

, my system says

Usage: wine PROGRAM [ARGUMENTS...]   Run the specified program
       wine --help                   Display this help and exit
       wine --version                Output version information and exit

which makes me think that wine is still installed somewhere since the system recognizes the wine command. Is wine completely uninstalled off of my system? If not, how would I do that? I installed using the directions on this page for Ubuntu 18.04: https://wiki.winehq.org/Ubuntu

1 Answer 1

0

Are you sure that the apt-get remove ... command did in fact remove wine? When I just tried it I got this message on 18.04.

$ sudo apt-get remove wine --purge
Reading package lists... Done
Building dependency tree
Reading state information... Done
Virtual packages like 'wine' can't be removed
0 upgraded, 0 newly installed, 0 to remove and 192 not upgraded.

As the message states, wine is a virtual package so you cannot remove it. You could remove it like this though:

$ sudo apt-get purge wine*
...
se 'apt autoremove' to remove them.
The following packages will be REMOVED:
  wine-stable* wine1.6* wine64*
0 upgraded, 0 newly installed, 3 to remove and 192 not upgraded.
After this operation, 869 kB disk space will be freed.
Do you want to continue? [Y/n] y
...

In this scenario you're telling apt-get to remove all packages that match your pattern, wine* which will get rid of all packages that match the pattern.

5
  • What is a virtual package? Does that indicate that all files downloaded and installed to my system from when I downloaded and installed Wine are now gone? Also, when I ran the commands in the second part of your message, it returned this: Reading package lists... Done Building dependency tree Reading state information... Done 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'
    – jflinux
    Commented Apr 9, 2019 at 4:09
  • Basically, I suppose I am just asking if the messages that I have provided from the terminal indicate that all Wine files that did not already come pre-installed with Ubuntu 18.04 (if any) are gone.
    – jflinux
    Commented Apr 9, 2019 at 4:18
  • @jflinux - if you have files in the directory w/ those names the wine* glob will match them. If that's the case change it to wine\*.
    – slm
    Commented Apr 9, 2019 at 5:00
  • @jflinux - a virtual package is covered in the FAQ - debian.org/doc/manuals/debian-faq/….
    – slm
    Commented Apr 9, 2019 at 5:02
  • 1
    You were right, changing it to $ sudo apt-get purge wine\* fixed the issue, thank you so much!!
    – jflinux
    Commented Apr 11, 2019 at 23:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .