Installing wine on ubuntu. Wine Basics for Beginners

Wine– an application that is a compatibility layer with Windows API, using libraries Windows to ensure the functionality of applications developed for the OS family Microsoft Windows in another environment, for example, in Ubuntu. Using Wine you can install and run various programs as if you were using Windows.
Wine is actively developing. Not all applications yet work stably enough in Wine, however Wine already used by several million users around the world.
The name of the program Wine (waɪn- between " Wayne" And " vine", rus. Wine) is a recursive acronym for the phrase " W ine I s N ot an E mulator" - Russian. "Wine is not an emulator."

Installing Wine

Installation from PPA

Due to the fact that Wine is actively developed, the Ubuntu repositories usually contain very old version. Therefore, it is recommended to install the latest version from the official Wine repository.

For latest versions of wine and ubuntu 64 bit

Sudo dpkg --add-architecture i386 sudo add-apt-repository ppa:wine/ wine-builds && sudo apt-get update sudo apt-get install --install-recommends winehq-devel

In general, it is not recommended to fill out and configure wine yourself. Working with wine is not very convenient. To install this or that program, you will have to crawl through a bunch of forums and blogs to understand which packages need to be installed and which libraries to add. Then there is a long process of solving problems, installing packages through winetricks and manual settings registry and so on. This is all very difficult even for experienced users, not to mention newbies. Therefore, it is recommended to download the configured wine prefix from here: http://forum.ubuntu.ru/index.php?topic=199897.0

Settings

Before using Wine to launch applications you need to run the setup program, which will create in your home directory catalog ~/.wine with the files necessary for work. To do this, either select the main menu item Applications→Wine→Configure Wine, or run the command in the terminal:

winecfg

Associating files with wine programs

To transparently run files using wine programs, we write small script. Let's say we need to open CAD files with Compass and zwcad.

#!/bin/bash # Determine the file extension dd = $1 ; razr =` echo $(dd:(-3)) ;` ff =` echo $(dd/\"/\"Z:) ` ; ff =` echo " \"Z:"$ff \" ` ; # Depending on the extension, launch the desired program case $razr in frw) env WINEPREFIX ="/home/" $USER "/.wine" wine start ` echo $ff ` & ;; cdw) env WINEPREFIX ="/home/" $USER "/.wine" wine start"C:\\Program Files\\ASCON\\KOMPAS-3D Viewer V9\\Bin\\kViewer.Exe" ` echo $ff ` & ;; dwg) env WINEPREFIX ="/home/" $USER "/.wine" wine start ` echo $ff ` & ;; dxf) env WINEPREFIX ="/home/" $USER "/.wine" wine start"C:\\Program Files\\ZWCAD 2009 Eng\\ZWCAD.exe"

` echo $ff ` & ;;

# Here you can add more extensions and programs

esac

Let's not forget to make our script executable

chmod +x wine_cad.sh

and associate the drawings with the script in the file manager.

Launching Windows applications In order to launch the application you need to open a terminal and write in it:

wine path/ to application/ program.exe If your application does not start or does not work correctly There is a list of applications with descriptions on the wine website, I recommend checking it first. http://appdb.winehq.org/ - The site has a search field. If your English is bad, then use the translator http://translate.google.com/. You can also open the folder containing the application you need to launch using file manager

, then click

right click mouse over the application and select the program to launch - Wine. Applications running via Wine that interact with Web pages require Gecko Gecko is a free web page rendering engine for the browser when working on the Internet wine. If wine does not work with the Internet and you do not start

windows exe< версия>

browser, then you don't need Gecko.<версия>Typically, when starting a web application, Wine automatically looks for Gecko first in /usr/share/wine/gecko. If Wine doesn't find the Gecko archive there, it will automatically download it from the Internet, but some applications don't like to wait for Gecko to load and freeze or crash. Gecko can be installed by running the command:

sudo apt-get install wine-gecko

Where must be replaced with the version of the installed Wine. Running via discrete video card

To run via

discrete video card

Save. Place in the game folder. Make it executable in properties. Place a link to the script on your desktop. Run a link instead of a game file. For even greater performance, you need to install a closed proprietary driver.

Winetricks

Winetricks– this is the installation script various components from Microsoft®, and some others. To get Winetricks in the terminal, enter:

sudo apt-get install winetricks

Winetricks contains several dozen packages of various libraries for wine. For example, to install DirectX™, enter:

Winetricks d3dx9

To view a list of all packages, enter:

Winetricks?

Also, Winetricks has a simple GUI. To run it, enter.

Wine (WINE Is Not an Emulator) – special program, compatibility layer, for running Win32 applications in UNIX-like systems. Simply put, this thing allows you to run Windows programs and games in your cozy Linux :).
The program is actively developing, but so far, unfortunately, not all applications work correctly in it (and some do not work at all). It’s also sad with games so far - full support There are no DirectX 10 or 11, only 9 and younger. (DirectX 10 support is being actively improved in the latest test builds). But nevertheless, there are a lot of games on DirectX 9. In this article we will install and configure Wine and install PlayOnLinux application, which is very useful for games. The installation will depend on your distribution, but the program setup itself is absolutely the same in the vast majority of distributions. There are two branches of Wine - stable and testing. In most cases, it is recommended to use the test one, since the program is actively developing and improving. Let's look at the installation for now stable version(examples for command line, however you can use graphical utilities, such as Ubuntu Software Center or Yast2 in OpenSUSE):

For Debian/Ubuntu/Mint:

sudo apt-get install wine winetricks

For OpenSUSE:

sudo zypper ar -r http://download.opensuse.org/repositories/Emulators:/Wine/openSUSE_13.1/Emulators:Wine.repo
sudo zipper in wine

sudo yum install wine
cd /tmp
wget http://www.kegel.com/wine/winetricks
chmod +x winetricks

Note. If you have a 64 bit system, then for correct operation 32-bit programs (and most games are like this), you need to configure Wine with a 32-bit prefix. To do this we enter:

WINEARCH=win32 WINEPREFIX=~/.wine winecfg

The settings window will open. You can leave everything as is.

Now we need to install the kit system libraries for the operation of our Windows applications. In the programs menu, find and run Winetricks(or from the terminal with the command winetricks). In the first window select ---Select the default wineprefix--- making money OK. In the second ---install a Windows DLL or component---OK


Remember:
You will need to mark with dots, as in the list. It is better to install not all at once, but several at a time. I'll separate them for convenience. Don't go far when installing, you need to agree with licensing agreements and so on. Error windows will pop up, click OK. Let's begin.

directly play, dmsynth

dotnet20

dotnet30(errors will appear and a window will open in the file manager and in the browser, download from the second link and move the file manager to this window. Type in the console winetricks and again select dontnet30. Before doing this, you need to check the Wine Settings so that the version of Windows XP or Vista is installed.

dxdiagn, gecko120, gfw, mfc40, mfc42, msasn1, msxml6, gdiplus, physx, quartz

vb5run, vb6run, vcrun2003, vcrun2005, vcrun2008, vcrun6, vcrun6sp6

wmp10, wsh56vb, wsh57, xact, xact_jun2010, xinput

Let's install the fonts. Choose Install a Font and indicate

corefonts, fontfix

Registry settings

Opening Change Settings and celebrate

1. DirectDrawRender(ddr) -- opengl
2. Multisampling Direct3D -- enabled
3. OffscreenRenderingMode(orm) -- fbo
4. PixelShaderMode(psm) -- enabled
5. Render TargetLockMode(rtlm) -- auto
6. UseGLSL(glsl) -- enabled (default) (For Nvidia video cards It is recommended to leave it disabled. This can significantly improve the performance of some games).
7. VertexShaders(vsm) -- hardware
8. VideoMemorySize 1024 (select the RAM value of your video card)
9. MouseWarpOverride(mwo) -- enabled (force)
We confirm our changes - OK.

That's all. Now some notes on installing software and games. First of all, do not under any circumstances install additional software that the program offers (all sorts of directixes, visual c++, and so on). Check them carefully and if something happens, uncheck them. Secondly, at the end of the installation, uncheck “Run the program”.

Now regarding the test version. There is a special repository for Ubuntu/Mint. To connect it and install a test version of Wine, enter in the terminal:

sudo add-apt-repository ppa:ubuntu-wine/ppa
sudo apt-get update
sudo apt install wine 1.7 winetricks

In some distributions (for example Debian), to install the test version, it must be compiled from source code. But this is beyond the scope of this article. Or you can install wine-staging, which is also a test but has a few extra features.

P.S. For those who like to see once is worth reading a hundred times - a short video tutorial on installing a test version of Wine on Ubuntu:

Not everyone has come to terms with the lack of Photoshop on Ubuntu, as well as a number of others useful programs or computer games, available only for Windows. There is a way out for such people and it is called Wine. No, there is no need to wash down your grief! It’s better to learn how to install and configure Wine on Ubuntu, and then you can install on your system some of the software that you really miss.

Installing Wine will allow you to use Windows applications on Linux.

Wine - special application, which allows you to run programs designed for Windows on Linux systems. This is the compatibility layer that uses Windows libraries, and then replaces them with system calls Linux so that software developed for other systems will work. Today, several million people already use Vine and are quite satisfied. The developers release updates very often, so the program gets better year after year. Some craftsmen even manage to run modern games through it.

Wine cannot be called an emulator, like VirtualBox. The creators tell us about this, “deciphering” the abbreviation through itself: W ine i s n ot e mulator (in smart words this is called a recursive acronym). Virtual machine is not created, the application simply implements the Windows API.

Installation and removal

Removal

It is important to know how to remove Wine. It doesn't always work properly. Some applications may be terribly slow or not launch at all. In this case, reinstalling the emulator to a higher new version should fix the problem.

However, you need to remove not only Vine itself from your computer, but also the folder in your home directory. The easiest way to do this is with the commands:

sudo apt-get purge wine
sudo apt-get autoremove
sudo apt-get clean
sudo apt-get install -f
rm -f ~/.wine
rm ~/.local/share/applications/wine/Programs
rm ~/.local/share/applications/wine*

This way we will receive the remote directory along with the application itself.

Launching programs

You can run programs using Wine different ways. The first, easiest one is through Nautilus:

  1. We find the software in the folder.
  2. Right-click on it.
  3. Select Wine as the program to launch.

The second, traditional one - through the terminal:

wine home/user/program.exe

Instead of home/user/program.exe, you must enter the path to the file that launches the application.

Where to get programs from?

We dealt with Vine. Now all that remains is to understand where to find this or that software. You won't find anything in the Ubuntu App Center, of course. Most users follow two paths:

  • look for assemblies on websites and forums;
  • use special shells.

Shells are applications that give Wine GUI and allowing you to load normal assemblies with all necessary packages. Most Popular:

  • It contains not only games, but also many programs that are constantly being improved to perfection.
  • Paid and, as a result, a higher quality shell.
  • WineWizard. New shell, which takes a slightly different approach. All successful solutions are collected here different users, all you have to do is look for them.

Well, forums and websites offer a lot different assemblies and instructions for installing games, office applications and whatever. If you set a goal and spend a certain amount of time, you can install almost any game on Ubuntu. For example, there is a video where a user demonstrates installed Fallout 4, which for many Linux users seems like a fantasy and a pipe dream.

Now you are aware that installing Wine on Ubuntu can greatly smooth out the rough edges of this system and once again annoy greedy developers. You also know how to remove Wine, configure it and update it. It is quite possible that over time you will learn to put necessary programs without outside help.

Wine is special software that allows you to run applications created for Windows on UNIX-like systems, including Linux. I think, if not all, then many have heard about Wine. I also want to graphomaniacally on this topic. Many articles about Wine say that you need to press the pimp, pull the squiggle, and then the program (enter the name) will work. I would like to leave this aside and talk about Wine in general, what subtleties there are, and how to use it in general. At least that's what I was missing at first.

In many distributions, Wine is installed out of the box - just run double click on a file with the extension .exe, and, quite likely, everything will work. If this wasn’t enough, then let’s dive into the details.

How to find out which version of Wine is installed?

Open the console and run the command:

winecfg

In the window that opens, select the “About the program” tab, where what you are looking for is located.

Where can I get Wine and which version should I choose?

Regarding the installation, I’ll just clarify that in many popular distributions Winetricks can be installed from repositories.

To run Winetricks for the default prefix, just run the command:

winetricks --gui

If you managed to create various prefixes, then use the command:

WINEPREFIX=~/.wine_example/ winericks --gui

Is there any program that will do all of the above for me?

Yes, there are two of them. Let's start with PlayOnLinux - https://www.playonlinux.com/ru/. This program contains a large number of scripts for installing various applications under Wine. Sometimes a distribution is needed, in some cases PlayOnLinux will download it itself and also create a separate prefix with the necessary settings Wine, download and install everything necessary components etc. In the list of programs for “general educational purposes” there are also those that do not work. They are highlighted in red. The interface of PlayOnLinux is simple and in Russian.

The second option is paid and quite known solution CrossoOver (https://www.codeweavers.com/). Positioned as a commercial version of Wine. The product, on the one hand, is aimed at running office applications. On the other hand, just like PlayOnLinux there are scripts for installation large quantity other applications, including games. Personally, I somehow didn’t really understand the “trick” of this program. It's not cheap, besides we're talking about not about a “once and forever” purchase, but about a subscription: 12 months - $40. At the same time, having used the test version (you can do this too, if you wish), I saw that the programs I was interested in (in particular Microsoft Office, as well as some other little things) work no better than with “simple” Wine, and I didn’t buy CrossOver. I can’t help but notice that the new, 15th, version of CrossOver is approaching, in which we are promised a lot of new things - for example, a working Office 2013. How it will work is, of course, a big question. But in the meantime.

What's the result?

But in the end it's simple:
- have the latest version of Wine;
— if you have any difficulties with any program, don’t be lazy to visit AppDB and just read the forums. For example, on the forums of many MMOs there are special threads about running them under Wine;
— additional components, if needed, install using Winetricks;
— install particularly “heavy” software using a special prefix.

By the way, about additional components. Many people try to install DirectX under Wine, in most cases this is completely unnecessary. If the game complains about the absence of a specific library, just install it through Winetricks.

In general, use Wine carefully. There is no point in switching to Linux just to try to run all your usual programs under Wine.

Firstly, there is a lot of good native software in Linux, just search harder and you will definitely find what you are looking for. For example, I have already picked up ones to replace the ones I used in the “windows”.

Secondly, “Wine” brings with it not only applications for Windows, but also various problems inherent to this platform. For example viruses. And given the fact that applications running under Wine have access to your home directory... Some, as far as I know, even install antiviruses under Wine. But this, it seems to me, is completely overkill.

You just need to be careful and not install everything. I run two games under Wine, and also, from time to time, the 7-zip archiver - I can’t find an analogue for Linux that suits me completely.

In contrast to the caveats, I would like to say that the mere presence of such software as Wine opens up many opportunities, especially if you take into account the fact that in Lately Wine is improving literally before our eyes.

Wine - free software, allowing GNU/Linux, *BSD and OSX users to run applications, including games, written exclusively for Windows. There is also an implementation of Wine for Windows, but we will not consider it in this article. Wine is a recursive acronym for "Wine Is Not an Emulator". This is an alternative implementation of the Win32 API.

In this article we will look at how to install wine linux mint, as well as winetricks and program configuration.

You can find out more about installing Wine on different OSes on the official website. We are interested in Ubuntu because Linux Mint based on it.

First, let's add support for 32-bit applications if you are using an x86_64 system. To do this, run:

sudo dpkg --add-architecture i386

Now we need to add a repository. To do this you need to run the following commands in the terminal:

wget -nc https://dl.winehq.org/wine-builds/Release.key

sudo apt-key add Release.key

Now important point! If you are using Linux Mint version 17.x, then add the repository with this command:

sudo apt-add-repository "deb https://dl.winehq.org/wine-builds/ubuntu/trusty main"

If 18.x, then:

sudo apt-add-repository "deb https://dl.winehq.org/wine-builds/ubuntu/xenial main"

Now you need to update the package indexes:

Warning! The Staging branch is no longer supported.

Stable branch:

Sudo apt-get install --install-recommends winehq-stable

Not stable branch:

sudo apt-get install --install-recommends winehq-devel

Intermediate branch

sudo apt-get install --install-recommends winehq-staging

Installation of wine in Linux Mint 18 is complete now setting up wine in linux mint.

Installing Winetricks on Linux Mint

First we need to download it:

wget https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks

Now we will give permissions to launch:

sudo chmod +x winetricks

For convenience, let's move Winetricks to the /usr/bin directory:

sudo mv -v winetricks /usr/bin

Now Winetricks can be launched simply by typing in the terminal, but I do not recommend doing this right away. It's better to configure wine first:

Now you know how to install wine in Linux Mint, now let's talk about configuration.

Setting up Wine in Linux Mint

Attention! Install the cabextract package, otherwise you may get the same error as in the video. This is done with the command:

sudo apt install cabextract

First, let's point out that a 32-bit prefix is ​​required:

export WINEARCH=win32

Now for Wine settings enter:

Here in the field "Windows version" indicate what you want. I recommend installing Windows 7 or 10.

Now run Winetricks and specify "Select the default path for wine" and press "OK". And in the next window indicate "Install font" and press "OK":

Please indicate here "allfonts" and press "OK". This will install all fonts at once. If there are errors, then install the fonts one by one:

After completion, the window will open again "What do you want to do with this wineprefix". And now indicate here "Install DLL or Windows component" and press "OK". Install the libraries you need here. You can bet everything. But you have to put one at a time! If you install several at once, there may be errors. I advise you to immediately install DirectX and Net Framework.

conclusions

In this article, we looked at how to install Wine on Linux Mint 18. If you have any questions, ask in the comments!