What Is Wine?
Installing Wine in Ubuntu (Two Methods)
Starting Up and Configuring Wine
You should give Wine a try if you have some Windows-only game or application that you really need and want to be able to use Linux for it.
Using the Wine PPA
This method is pretty straightforward. First, we need to make sure that we uninstall any older version of Wine:
This is usually not needed considering there is an updated repository available, but sometimes the PPA repository may have a delay until the packages are built and uploaded. Usually this happens immediately after a new version of Wine is released and there are no updated packages in the PPA. This is where compiling Wine from source could come in handy. Also, Ubuntu 10.10 Maverick Meerkat comes with the latest stable release of Wine, which is 1.2, so if you want the latest development release you will need to install it from the PPA or compile it from source.
First, make sure you have the sources repositories enabled, meaning a line that starts with deb-src is in your /etc/apt/sources.list file, like the following:
Next, enter in wine-1.3.9 directory and issue the following commands to compile and install it:
If you need to uninstall Wine, issue the following command from within the wine-1.3.9 directory:
winecfg is used to configure Wine and change settings like sound, graphics, Windows version and so on. Wine uses the winecfg utility for configuration, which you can start either by typing winecfg in a terminal or pressing Alt+F2 and typing it there, followed by Enter. Note that the default settings usually will do, so it's not necessary to change the configuration options after installing Wine. When it starts for the first time, winecfg will prompt you to install Gecko, a web rendering engine used to embed HTML in applications (the same engine which is used by Firefox). It is recommended that you install it.
If you don't install Gecko now, you'll be prompted later when it is needed by some application or you will be able to install it manually using the winetricks script (which is explained below this section). After installing Gecko, let's have a look at the Wine configuration window:
I'll briefly explain each tab:
- Applications tab: this is used to set different Windows versions for different applications. The default (Windows XP) should be fine for most of them.
- Libraries tab: here you can add dynamic link libraries (DLLs) and specify whether they should be a Wine builtin or a native Windows binary; this will be used to copy various libraries needed by certain games or applications to run properly.
- Graphics tab: in this tab you can specify graphics settings, emulate a virtual desktop and choose its resolution, change Direct3D vertex shader options and set fonts dots per inch (DPI).
- Desktop Integration tab: in this tab you will be able to change the look of Windows applications that run through Wine, and also to change the theme which it uses (this is explained below in the section Customizing Wine).
- Drives tab: this tab allows you to set drive mappings, which will give Wine access to certain devices and drives on your system. Default is usually fine, but you may need to add an optical drive here for applications which require the CD or DVD.
- Audio tab: the first time you click on this tab a message window will appear notifying you that a recommended driver has been selected. Click OK, then in the Audio tab click Apply. You can also test the sound using the Test Sound button. Default settings should be fine.
- About tab: optionally you can fill in the Owner and Organization text fields (anything will do).
Winetricks is a powerful script which automates installation of various useful packages, offering a friendly interface to do so. Before downloading and using winetricks, first let's install the cabextract package, which is a native Linux application that extracts Microsoft Cabinet files (CAB), and is available in the repositories.