How to Properly Install Wine in Mint-19?

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Post Reply
377Ohms
Level 2
Level 2
Posts: 89
Joined: Mon Nov 09, 2015 10:49 pm

How to Properly Install Wine in Mint-19?

Post by 377Ohms » Sun Aug 12, 2018 7:54 am

So I'm seeing various attempts to properly install Wine in Mint-19 Cinnamon: The winehq.org recipe (mixed results, no easy integration with the GUI), through the Software Manager (old versions, mixed results), and combinations of the two.

For me this is not good. I need Wine, and having it available at install is what drove me to Mint-17. But as I try to move to Mint-19 I discover Wine is gone out of the box, and approaching a Wine install from Software Manager is a crapshoot IMO.

I'm OK with following clear step-by-step instructions and installing an up to date version of Wine with UI integration like in Mint-17.

But where are those instructions?

If they don't exist, what is the next best recommendation?

Thanks, David

rbeltz48
Level 4
Level 4
Posts: 242
Joined: Mon Jan 16, 2012 3:08 pm
Location: Florida, USA

Re: How to Properly Install Wine in Mint-19?

Post by rbeltz48 » Sun Aug 12, 2018 8:11 am

I installed Wine on both Mint 19 MATE and LMDE3 Beta MATE. These instructions worked just fine on both of these releases. For Mint 19, use #4 as opposed to #4A which is for LMDE3. For #6 I used the command for the stable version of Wine. I did NOT need to key in #7 or #8 as I was able to install and run a Windows .exe program after I keyed in #6. Go to a Terminal and key in the following commands one after another:

1. sudo dpkg --add-architecture i386
2. wget -nc https://dl.winehq.org/wine-builds/Release.key
3. sudo apt-key add Release.key

For Mint 19
4. sudo apt-add-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ bionic main'

For LMDE3
4A. sudo apt-add-repository 'deb https://dl.winehq.org/wine-builds/debian/ stretch main'

5. sudo apt-get update
6. If you want to get stable version: sudo apt-get install --install-recommends winehq-stable
If you want to get develpment version: sudo apt-get install --install-recommends winehq-devel
If you want to get staging version: sudo apt-get install --install-recommends winehq-staging

7. WineARCH=win32 WINEPREFIX=~/.wine wine wineboot (this will initiate environment for wine, if you want win64 change value win32 to win64)
if you somehow massed up you can always do sudo rm -rf ~/.wine and do above commands again to initiate it.
8. sudo apt-get install winetricks (winetricks is useful when you need to install windows library,etc)

377Ohms
Level 2
Level 2
Posts: 89
Joined: Mon Nov 09, 2015 10:49 pm

Re: How to Properly Install Wine in Mint-19?

Post by 377Ohms » Sun Aug 12, 2018 9:13 am

@rbeltz48, Thank you for your reply, but I think you're making the point of my O.P.

What you are doing at first glance looks a lot like the winehq.org recipe, which may work, or it may send you into a dependency death spiral. Even the winehq post warns of possible missing pieces, even though they're targeting specific distros and versions.

Also unless it auto-magically happens somehow, you are not showing any integration with the Mint Cinnamon Menu and User Interface.

Finally, just running an .exe under Wine doesn't tell you if you actually have 32-bit emulation. AFAIK a Windows .exe can be a 32-bit or a 64-bit application. It's impossible to tell which by simple inspection.

Again: What I would like to see is a set of tried and true instructions that leave the user with a current version of Wine installed in Mint-19 Cinnamon complete with menu entries and icons - just like it used to be in Mint.

rbeltz48
Level 4
Level 4
Posts: 242
Joined: Mon Jan 16, 2012 3:08 pm
Location: Florida, USA

Re: How to Properly Install Wine in Mint-19?

Post by rbeltz48 » Sun Aug 12, 2018 9:21 am

The instructions given here worked just fine for me. The Windows program I need is running OK under Mint 19 MATE and LMDE3 Beta MATE. If you are not satisfied with these instructions or they don't work for you after running them, then I suggest that you drop Linux Mint and search for another distro.

377Ohms
Level 2
Level 2
Posts: 89
Joined: Mon Nov 09, 2015 10:49 pm

Re: How to Properly Install Wine in Mint-19?

Post by 377Ohms » Sun Aug 12, 2018 6:30 pm

@rbeltz48,

While I appreciate your replies, you have still not read and understood what I'm asking for here. Remember the subject of this thread: "How to Properly Install Wine in Mint-19?". I want to emphasize the word "Properly" here. While I certainly can install Wine using the WinHQ recipe like you did, it leaves me with a very user unfriendly instance of Wine on my machine unless I do a large amount of work to build hooks into the Mint UI - something that used to come with Mint straight out of the box.

Meanwhile I have verified the following:

1. Your procedure is fundamentally just a copy of the winehq.org recipe, with all the attendant problems.

2. Your procedure leaves an inexperienced user with what amounts to a crippled Wine installation. There is zero integration with the Mint Cinnamon user interface. No Menu entries at all. (Unfortunately I do not know enough about Mint to do this myself in a reasonable amount of time.)

3. Your procedure does not address issues like the installation of Mono (.NET) or Gecko (HTML). Hopefully the WineHQ implementation will handle those dependency problems with in-line installer scripts when needed. But without further testing I cannot say. A proper Wine installation should support both x32 and x64 applications as well as at-least Mono and Gecko engines.

377Ohms
Level 2
Level 2
Posts: 89
Joined: Mon Nov 09, 2015 10:49 pm

Re: How to Properly Install Wine in Mint-19?

Post by 377Ohms » Sun Aug 12, 2018 8:16 pm

A couple of updates...

1. I installed a Windows password generator application PWGen under Wine. It did not install any desktop icons or Menu entries in Mint. However the program did install and I am able to run it from the command line or by double clicking on the application's .exe from Nemo in the /home/username/.wine/ hidden (dotted) directory tree. This led me to believe there was no integration between Wine as installed with the winehq.org recipe and the Mint UI at all.

Later I installed the Windows 64-bit version of the circuit simulator application LTspice from linear.com. That also installed as expected in /home/username/.wine/, but this time there WERE shortcuts with icons installed on the Mint desktop and in the Menu under "All Applications". So this time there was some automatically generated integration with the Wine installer and the Mint UI.

I don't know why this behavior is inconsistent. But at least I did see one Wine application result in some integration with the Mint UI after install.

2. I ran the stand-alone Windows FFMpeg transcoder front-end applicaton WinFF from its .exe. This is because I know WinFF under Wine requires both Mono and Gecko support to handle .NET and HTML dependencies. Wine as installed using the winehq.org recipe DID automatically flag the missing Mono and Gecko support and then offered to auto-install them via winehq.org. (It also warned to use the distro's repositories instead, but from past experience what is in the default repositories is very likely hopelessly out of date). So I let Wine auto-install the Mono and Gecko dependencies, and much to my surprise the WinFF application works OK. Now, since WinFF is a stand-alone application I will need to create my own integration with Mint's UI.

So the take away is that there IS in-fact a minor level of Mint UI integration with Wine, but very early on I'm seeing it work inconsistently.

377Ohms
Level 2
Level 2
Posts: 89
Joined: Mon Nov 09, 2015 10:49 pm

Re: How to Properly Install Wine in Mint-19?

Post by 377Ohms » Sun Aug 12, 2018 10:33 pm

(A) Manually adding a stand-alone Windows .exe program under Wine to the Mint Cinnamon Wine Menu:

Right-click Menu (desktop lower-left) then click Configure.

Now click the Wine icon in the left pane of the Main Menu window, then click the New Item button in the right border. A Launcher Properties window will appear.

Type a Name for the application, next click the Browse button and navigate to and click the program's .exe file. The full path and .exe will appear in the Command box.

Click in the Command box and move the cursor to the very beginning of the line, then type wine (all lower-case) followed by a single space.

Next add an optional description in the Comment box if you like, then click OK. Close the Menu Editor and Menu windows.

Now click Menu in the desktop's lower-left, then hover the mouse pointer over the Wine icon on the left side of the Menu. On the right you should see an entry for the Windows program you just added. Clicking it launches the program via Wine.

(B) Manually adding the winecfg utility to the Mint Cinnamon Wine Menu:

Do exactly as above for adding a Windows stand-alone .exe to the Menu, but with the following two changes:

1. Instead of pointing to a Windows .exe in the Launcher Properties window Command box, point to the winecfg program here:

Code: Select all

/opt/wine-stable/bin/winecfg
2. Do NOT add wine (with a single space after it) before the winecfg line you just entered in the command box.

NOTE: These simple examples do not add a custom icon to the newly added Menu items (yes there is a way to do this too, but it's not as easy). Mint just defaults to a generic icon instead.

377Ohms
Level 2
Level 2
Posts: 89
Joined: Mon Nov 09, 2015 10:49 pm

Re: How to Properly Install Wine in Mint-19?

Post by 377Ohms » Sun Aug 12, 2018 11:43 pm

377Ohms wrote:
Sun Aug 12, 2018 10:33 pm
NOTE: These simple examples do not add a custom icon to the newly added Menu items (yes there is a way to do this too, but it's not as easy). Mint just defaults to a generic icon instead.
Icons...

It turns out adding or changing icons in Mint Cinnamon Menu items seems pretty simple. In the Launcher Properties window just click the icon picture and navigate to a new icon file and click. I find an icon that's between 16x16 and 48x48 pixels fits well. However It seems Mint auto-scales images, but the image should have a 1:1 aspect ration [square] to begin with or there's some distortion.

To get to the Launcher Properties:

Right-Click Menu (desktop lower-left) > Configure > Menu Tab > Open the menu editor

Then select the Menu item on the left side of the window, then right-click the item you want to edit on the right side, then click Properties in the drop-down menu. The Launch Properties window will open. The icon button is on the left, click it.

Yet another approach is to visit an application's Web page and scrape an image off of it for use as an icon.

To get an icon for a stand-alone Windows program, try looking in the source code. For example all the icons for the WinFF stand-alone Windows program are here:

https://github.com/WinFF/winff/tree/mas ... inff-icons

Another way is to take a screenshot of the application when it is open and use an image editor to crop and reduce the image to icon size.

Or try doing an image Web search under the name of the application.

Or you could use a generic icon from Mint itself. Browse around in here:

/usr/share/icons

NOTE: If you change themes, I don't know what happens to these manually edited icons in Mint. I'm still learning...

Post Reply

Return to “Newbie Questions”