Wine windows program loader

Поскольку вы находитесь здесь, я предположу, что вы пользователь Linux. И время от времени вы задаетесь вопросом: могу ли я запускать приложения windows в Linux?

Ответ на этот вопрос — да, вы можете запускать приложения Windows в Linux. Вот некоторые способы запуска программ Windows в Linux:

  • Установка Windows на отдельный раздел жесткого диска
  • Установка Windows в качестве виртуальной машины в Linux

Оба они работают просто отлично. Но они несколько требовательны к ресурсам.

Если вам нужно использовать только небольшое приложение Windows, установка Windows на отдельный раздел жесткого диска или в качестве виртуальной машины неэффективна. Более того, виртуальная машина не может использовать всю мощность вашей машины. Итак, каково же решение?

Не волнуйтесь, есть другой способ использовать программное обеспечение Windows в Linux. Он называется Wine. Если вы еще не знакомы с ним или являетесь новичком в мире Linux, эта статья для вас.

В этом руководстве для начинающих я покажу вам, что такое Wine и как использовать его для запуска программ Windows в Linux. Я использовал здесь Ubuntu, поскольку Ubuntu является одним из лучших дистрибутивов Linux для начинающих, но любой другой дистрибутив Linux будет иметь более или менее те же шаги (за исключением команд в дистрибутивах на базе Arch или Fedora).

Использование Wine для запуска программ Windows в Linux

Wine означает Wine Is Not an Emulator. И WINE на самом деле является акронимом этого слова. И, как уже говорилось ранее, это даже не виртуальная машина.

Скорее это уровень совместимости для запуска приложений Windows на UNIX-подобных или POSIX-совместимых операционных системах (например, Linux, Mac, BSD). В то время как виртуальная машина или эмулятор имитирует внутреннюю логику Windows, Wine переводит эту логику Windows в родную логику UNIX/POSIX-совместимости.

Говоря простыми и нетехническими терминами, Wine преобразует внутренние команды Windows в команды, которые ваша Linux-система может понимать как родные.

Установка Wine

Существуют различные способы установки Wine на вашу систему. Поскольку это руководство для начинающих, я опишу самый простой из них.

Почти все дистрибутивы Linux поставляются с Wine в репозитории пакетов. Чаще всего в репозитории пакетов доступна последняя стабильная версия Wine. Установить Wine на Ubuntu так же просто, как открыть терминал и выполнить следующие команды:

sudo apt update
sudo apt install wine

Однако если вы используете 64-разрядную установку Ubuntu, вам потребуется выполнить эти дополнительные команды:

sudo dpkg --add-architecture i386

Это добавит поддержку 32-разрядной архитектуры в ваш дистрибутив, что поможет вам при установке определенного программного обеспечения.

Какие приложения Windows поддерживаются Wine?

Существует большое количество приложений Windows, которые в настоящее время полностью поддерживаются Wine. Они будут работать без каких-либо проблем.

Однако каждый день разрабатываются новые приложения Windows. Многие из них не будут работать в Wine так, как мы хотим. Но темпы развития Wine также стремительны, поддержка новых приложений добавляется постоянно.

И для отслеживания этого существует специальная база данных.

База данных приложений Wine содержит почти 24 000 приложений, имеющих различные статусы в зависимости от того, насколько хорошо эти приложения работают в Wine. Если вы хотите быстро проверить рейтинг приложения, которое вы хотите использовать в Wine, вы можете заглянуть туда. Вот значение этих рейтингов:

  • Platinum: Эти приложения устанавливаются и безупречно работают в «готовом» Wine.
  • Gold: Эти приложения работают безупречно с некоторыми специальными настройками.
  • Silver: Приложения с незначительными проблемами помечаются как Silver.
  • Bronze: Бронзовые имеют серьезные проблемы, которые достаточно сильно влияют на использование.
  • Garbage: Они просто не будут работать в Wine.

Отзывы, процедура установки, с какой версией Wine оно тестировалось и различные полезные данные также доступны для каждого приложения здесь.

Разумеется, база данных приложений Wine — это в основном пользовательские данные, поэтому вы всегда можете попробовать запустить приложение с другой версией Wine и поделиться своими результатами с остальными членами сообщества.

Поиск приложения в базе данных приложений Wine

Давайте посмотрим, как мы можем найти приложение в базе данных приложений Wine.

Перейдите в раздел База данных приложений Wine. Нажмите кнопку Browse Apps (Обзор приложений) на левой боковой панели.

Поиск приложения в Wine AppDB

Напишите имя приложения, которое вы хотите найти, в поле Имя.

Фильтр имен Wine AppDB

Нажмите на ссылку-приложение из результата поиска.

Вы увидите описание приложения. Там будет список различных версий с рейтингом их совместимости с конкретной версией Wine.

Страница приложения Wine AppDB

Давайте нажмем на ссылку «Последняя версия».

Это главная страница, которую вам нужно проверить. Там будет подробная информация об этой конкретной версии.

Подробная информация о приложении

Вы получите представление о том, что будет работать, а что нет. Также здесь будет приведена процедура установки, если для установки потребуются какие-либо дополнительные задачи.

Начало работы с Wine

Прежде чем приступить к установке и запуску приложений в Wine, мы должны иметь четкое представление о некоторых вещах и о том, как настроить Wine для использования:

WinePrefix

Приложениям Windows необходим диск C:. Wine использует для этой цели виртуальный диск C:. Каталог этого виртуального диска C: называется wineprefix. Прежде всего, нам нужно создать wineprefix. Для этого откройте терминал и введите следующую команду:

winecfg

Это создаст wineprefix и откроет окно конфигурации для Wine. Вы можете изменить параметры конфигурации, если хотите, или оставить все как есть и закрыть его. Теперь вы можете найти виртуальный диск C: по адресу

$HOME/.wine/c_drive
WinePrefix C: Диск

Общее правило — устанавливать каждое новое приложение в новый wineprefix. Мы можем создавать и поддерживать несколько wineprefix вручную. Но эта задача покажется довольно утомительной для новичков. Поэтому мы пока пропустим эту часть. Но позже я покажу, как можно легко выполнить эту часть.

Установка приложения с помощью Wine

Установка поддерживаемого приложения в Wine обычно не сложнее двойного щелчка по установочному файлу. Однако сейчас мы рассмотрим пошаговое руководство по установке 7-zip в Wine.

Прежде всего, проверьте рейтинг 7-zip в базе данных приложений Wine. Он имеет рейтинг Platinum, так что все готово. Откройте конфигурацию Wine ( winecfg ) и установите версию Windows на Windows 7.

Wine Windows 7

Щелкните правой кнопкой мыши на установочном файле 7-zip и выберите Open With Wine Windows Program Loader.

Установочный файл 7-zip

Видите путь к конечной папке? Установка 7-zip распознала виртуальный диск C: из wineprefix.

7-zip Установочный каталог в Wine

Завершите установку и перейдите в каталог установки [ $HOME/.wine/drive_c/Program Files/7-zip/ ] из браузера файлов.

Щелкните правой кнопкой мыши на файле 7zFM.exe и выберите Свойства > Открыть с помощью.

Установка загрузчика .exe по умолчанию

Выберите Wine Windows Program Loader и закройте окно. Дважды щелкните на файле 7zFM.exe.

7-zip работает в Wine

И вот, пожалуйста! Для создания ярлыка на рабочем столе щелкните правой кнопкой мыши на файле.

Создание ярлыка 7-zip

Теперь переместите ссылку на рабочий стол.

Переместить ярлык на рабочий стол

Теперь вы можете запускать 7-zip просто с рабочего стола. Все, что вам нужно сделать, это дважды щелкнуть по значку.

Запустите 7-zip с рабочего стола

Если вы хотите получить доступ к своим файлам в Linux, они обычно находятся на диске Z:.

Каталог Linux на диске Z:

Вы можете использовать 7-zip так же, как и в Windows — для извлечения и создания архивов и тому подобного.

Давайте сделаем все (намного) проще

Вы могли заметить, что в Wine Application Database при обзоре каждой версии приложения упоминается конкретная версия Wine.

Это связано с быстрыми темпами развития Wine. Хотя приложение работает с текущей версией Wine, оно может не работать с будущей версией из-за внесенных изменений.

Кроме того, я упоминал об установке каждого приложения в свой собственный свежий wineprefix. Таким образом, у приложения нет шансов помешать другому. И делать все это вручную, как правило, из терминала, отнимает много времени, утомляет и порой сбивает с толку.

На помощь приходит PlayOnLinux. Он предоставляет удобный интерфейс для выполнения всех этих действий. Для установки PlayOnLinux на Ubuntu просто выполните эту команду:

sudo apt install playonlinux
Интерфейс PlayOnLinux

С помощью PlayOnLinux вы можете легко выполнить любую задачу, связанную с Wine, используя красивый и интуитивно понятный графический интерфейс:

  • Установка и удаление приложений.
  • Создание, обновление и удаление wineprefixes.
  • Поддерживать Wine различных архитектур и версий.
  • Запуск и создание ярлыков для установленных приложений.
  • И так далее…

Но все же вам нужно будет проверить базу данных приложений Wine на предмет отзывов, процедур установки и тому подобного.

Преимущества использования Wine

Когда речь идет о запуске приложений Windows в системе Linux, Wine предоставляет множество преимуществ по сравнению с использованием эмуляторов или виртуальных машин.

  • Производительность: Wine не подвержен снижению производительности, которое в противном случае происходит при эмуляции.
  • Нативный опыт: Нет необходимости открывать Wine перед запуском приложения Windows. Как именно работает Wine, станет более понятно из этой цитаты с официального сайта,

Wine можно рассматривать как эмулятор Windows примерно так же, как Windows Vista можно рассматривать как эмулятор Windows XP: оба позволяют запускать одни и те же приложения, переводя системные вызовы примерно одинаковым образом. Настройка Wine для имитации Windows XP мало чем отличается от настройки Vista для запуска приложения в режиме совместимости с XP.

Производные Wine

Существует довольно много проектов для запуска приложений Windows на других платформах, основанных на Wine:

  • CrossOver: CrossOver разработан компанией CodeWeavers. Она основана непосредственно на Wine с некоторыми изменениями и собственными дополнениями. На самом деле, в CodeWeavers работает большая часть разработчиков Wine. В отличие от быстрых релизов Wine, релизы CrossOver более стабильны. Единственным и основным недостатком является то, что Crossover не является бесплатным.
  • PlayOnLinux: PlayOnLinux полностью основан на Wine. Он обеспечивает более легкий путь для установки и управления приложениями с помощью Wine. PlayOnLinux бесплатен. Он также доступен для Mac как PlayOnMac.
  • ReactOS: ReactOS — это совершенно другая операционная система с открытым исходным кодом для запуска приложений Windows. В ней повторно используется значительное количество кода из Wine. Однако этот проект находится в разработке уже более десяти лет, и я не стал бы его рекомендовать.

Дополнительные советы по использованию Wine

Winetricks

Это еще одна важная часть использования Wine. Winetricks — это вспомогательный скрипт для загрузки и установки различных перераспределяемых библиотек времени выполнения, необходимых для запуска некоторых приложений в Wine. Они могут включать замену компонентов Wine, использующих библиотеки с закрытым исходным кодом. Winetricks поставляется вместе с установкой Wine на Ubuntu.

Для запуска winetricks выполните эту команду:

winetricks
Winetricks

Существует множество вариантов помощи в решении различных задач.

Установка приложения с помощью Winetricks

Если вы установите приложение из winetricks, оно будет установлено в отдельный wineprefix. Давайте установим VLC:

Winetricks – Установить приложение
Winetricks – установить VLC

После этого начнется загрузка установочных файлов VLC. А затем проведет вас через весь остальной процесс. Это довольно просто.

Установка DLL или компонентов Windows и другое

Вы можете выбрать wineprefix из winetricks и установить различные библиотеки и компоненты, необходимые для запуска приложения, а также выполнить другие операции.

Сценарии Winetricks
Библиотеки и компоненты Winetricks

Примечание: Если использование winetricks кажется вам сложным, это совершенно нормально. Я тоже так считаю. По этой причине я всегда использую PlayOnLinux. PlayOnLinux может делать все, что вам может понадобиться от winetricks.

Для получения дополнительной информации вы можете ознакомиться с FAQ и документацией по Wine.

Я надеюсь, что это руководство для начинающих по использованию Wine в Linux будет вам полезно. Теперь вы можете запускать программы Windows в Linux без установки виртуальной машины или двойной загрузки.

Сообщите нам, если у вас есть вопросы или мнения, в разделе комментариев ниже.

Новости Ubuntu Linux в Telegram

Телеграм канал об Ubuntu и Linux! 🐧 Здесь вы найдёте свежие новости, полезные советы, инструкции, а также обсуждения новых функций и обновлений. Подписывайтесь, чтобы изучать Linux, оптимизировать систему и делиться опытом.

Warp Terminal

As you’re here, I’m going to assume that you’re a Linux user. And every once in a while, you find yourself asking: can I run windows applications on Linux?

The answer to that question is yes. Yes, you can run Windows applications in Linux. Here are some of the ways for running Windows programs with Linux:

  • Installing Windows on a separate HDD partition
  • Installing Windows as a virtual machine on Linux

Both of them work just fine. But they are somewhat resource hungry.

If you only need to use a small Windows application, installing Windows on a separate HDD partition or as a Virtual Machine is not efficient. Moreover, Virtual Machine can’t utilize the total power of your machine. So, what is the solution?

No worries, there is another way to use Windows software on Linux. It’s called Wine. If you aren’t yet familiar with it or you are a beginner in the world of Linux, this article is for you.

In this beginner’s guide, I’ll show you what Wine is and how to use it to run Windows software on Linux. I have used Ubuntu here as Ubuntu is one of the best Linux distros for beginners, but any other Linux distribution will have more or less the same steps (except for the commands in Arch or Fedora-based distros).

Using Wine to run Windows programs in Linux

Wine stands for Wine Is Not an Emulator. And WINE is actually an acronym for that. And as previously stated, it’s not even a virtual machine.

Rather it is a compatibility layer for running Windows applications on UNIX-like, POSIX-compliant operating systems (e.g. Linux, Mac, BSD). While a virtual machine or emulator simulates internal Windows logic, Wine translates those Windows logic to native UNIX/POSIX-complaint logic.

In simple and non-technical words, Wine converts internal Windows commands to commands your Linux system can natively understand.

Installing Wine

There are various ways to install Wine on your system. Almost all the Linux distros come with Wine in their package repository. Most of the time the latest stable version of Wine is available via the package repository.

If you are using a 64-bit installation of Ubuntu, you will need to add 32-bit architecture support on your distro which will benefit you in installing specific software. If you don’t know whether you have a 32-bit installation or 64-bit, check this article on how to check if you have a 32-Bit or 64-Bit Computer.

Once confirmed, do this by executing the following command:

sudo dpkg --add-architecture i386

In Ubuntu, you can install Wine by:

sudo apt update
sudo apt install wine

Get the latest WINE version (optional)

But in the case of Ubuntu 22.04 LTS, the available package in the repo is Wine v6.0.3, while the latest stable release is v7.0.1. In the case of software like Wine, which receives significant updates frequently, always try to remain in the latest stable release. To do this in Ubuntu, first, you need to add the 32-bit architecture with the above step. Then download and add the repository key:

sudo mkdir -pm755 /etc/apt/keyrings
sudo wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key

In the next step, you need to download the Wine source file. For that, you need wget installed.

sudo apt install wget

Also, you should know which version of Ubuntu is running on your system. In my case, I was running Ubuntu 22.04 Jammy Jellyfish.

To know your version, run this command in a terminal window:

lsb_release -cs

Once you get your version name, replace this in place of jammy and execute the command below:

sudo wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/jammy/winehq-jammy.sources

Now update the package information.

sudo apt update

Finally, install the latest stable version of Wine with:

sudo apt install --install-recommends winehq-stable

You can use winehq-devel or winehq-staging for Development and Staging branch respectively.

Getting Started with Wine

Before we go on installing and running applications in Wine, we should have a clear idea about a few things and about how to configure Wine for usage:

WinePrefix

Windows applications need a C: drive. Wine uses a virtual C: drive for this purpose. The directory of this virtual C: drive is called wineprefix. First of all, you need to create a wineprefix. To do that, fire up a terminal and enter this command:

winecfg

Here it prompts you to install the Wine Mono package needed for the .NET application to work properly. You can press the Install button to do this job.

Install Wine Mono using the installer 

This will create a wineprefix and open the configuration window for Wine. You can change the configuration options or let it be as it is and close it.

Wine Configuration Window

Now, you can locate the virtual C: drive at

$HOME/.wine/c_drive

C: Drive inside the Wine directory on User’s home directory 

The general rule is to install each new application into a fresh wineprefix. You can create and maintain multiple wineprefix manually. But that task would seem rather tedious for beginners. So, we will skip that part for now. But, later I will show how to do that part with ease.

Which Windows applications are supported by Wine?

A large number of Windows applications are currently fully supported by Wine. They will run without any hassle.

However, new Windows applications are being developed every day. Many of them wouldn’t function as we want on Wine. But the development pace of Wine is also rapid, and support for new applications is being added all the time.

And there is a dedicated database for keeping track of just that.

Wine Application Database has almost 28,000+ applications rated with different statuses depending upon how well those applications run in Wine. If you want to quickly check the rating of the application you want to use in Wine, you can take a look there. Here is the meaning of those ratings:

  • Platinum: These applications install and run flawlessly in out-of-the-box Wine.
  • Gold: These applications work flawlessly with some special configurations.
  • Silver: Applications with minor issues are tagged as Silver.
  • Bronze: The Bronze ones have major issues that seriously affect usage.
  • Garbage: These simply won’t run on Wine.

Reviews, Installation Procedure, which Wine version it was tested against and various useful data are also available for each application here.

Of course, Wine Application Database is mostly user-generated data, so you are always welcome to try running an application with a different version of Wine and share your result with the rest of the community.

Finding an Application in Wine Application Database

Let’s see how we can find an application in Wine Application Database.

Go to Wine Application Database. Click Browse Apps from the left sidebar.

Browse applications in Wine Application Database using various filters like name, rating, etc.

Click on the link to the application from the search result. You’ll see a description of the application. There will be a list of various versions with their compatibility rating with a specific Wine version.

The details page for the selected application with the list of versions and their statistics

Let’s click on the latest version link. This is the main page you need to check. There will be detailed information about that specific version.

Detailed information about a particular version of the application in Wine Application Database

Installing an Application with Wine

Installing a supported application in Wine is generally as easy as double-clicking on the installation file. However, you will now see a step-by-step guide for installing 7-zip on Wine.

First of all, check for 7-zip rating on Wine Application Database. It has a Platinum rating, so we are good to go. Open Wine configuration ( winecfg ) and set the Windows Version to Windows 7 (Shown in the above screenshot).

Right-click on the 7-zip installation file and select the Open With Other Application option.

Select Open With Other Application option from right-click context menu

After that, select Wine Windows Program Loader.

Select Wine Windows Program Loader as the application to open .exe type files

See that destination folder path? The 7-zip installation has recognized the virtual C: drive from wineprefix.

Select Install in the 7-zip installer to install the program

Finish the installation and you can now open the 7-zip application from the Ubuntu Activities overview.

Open 7-zip from Ubuntu Activities Overview

All you have to do is click on the icon. If you want to access your files on Linux, they are generally located in Z: Drive.

7-zip list the contents of users’ home directory

You can use the 7-zip just as you would use it on Windows – for extracting and creating archives and such.

Uninstalling an Application with Wine

As said above, installing an application is easier with Wine. To uninstall an application, you have a Wine Uninstaller tool. You can access this tool by entering the terminal:

wine uninstaller

This will open the uninstaller window. Here, the list of installed applications will be present. You need to select the application, 7-zip in this case, and press Modify/Remove button as shown below:

Modify/Remove an application installed using the Wine Uninstaller tool

This will initiate the uninstall process and can be completed easily on an application basis.

Let’s make things (a lot) Easier

You might have noticed that, in Wine Application Database, a specific Wine version is mentioned with every version of the application reviews.

It is because of the rapid development rate of Wine. Though an application runs with the current version of Wine, it might not run with a future version, because of the changes made.

Also, I’ve mentioned installing each application in its own fresh wineprefix. So, an application has no chance of interfering with another. And doing all these manually, usually from the terminal, is time-consuming, tiresome, and sometimes confusing.

PlayOnLinux is here to rescue you. It provides a nice interface for doing all these things easily. For installing PlayOnLinux on Ubuntu, simply run this command:

sudo apt install playonlinux

PlayOnLinux Interface

You can easily perform every task related to Wine with PlayOnLinux from a beautiful and intuitive graphical interface:

  • Installing & Uninstalling applications.
  • Creating, Updating & Removing wineprefixes.
  • Maintain Wine of different architecture and versions.
  • Run & Create shortcuts for installed applications.
  • And so on…

But still, you will need to check Wine Application Database for reviews, installation procedures, and such.

Advantages of using Wine

When it comes to running Windows applications on Linux systems, Wine provides many advantages over using emulators or virtual machines.

  • Performance: Wine is immune to the performance loss that otherwise occurs while emulating.
  • Native Experience: There is no need to open Wine before running a Windows application. Exactly how Wine works will be clear from this quote from the official site,

Wine can be thought of as a Windows emulator in much the same way that Windows Vista can be thought of as a Windows XP emulator: both allow you to run the same applications by translating system calls in much the same way. Setting Wine to mimic Windows XP is not much different from setting Vista to launch an application in XP compatibility mode.

Wine Derivatives

There are quite a number of projects for running Windows applications on other platforms, based on Wine:

  • CrossOver: CrossOver is developed by the company named CodeWeavers. It is directly based on Wine with a few tweaks and proprietary add-ons. In fact, CodeWeavers employs a large portion of Wine developers. Unlike the rapid releases of Wine, CrossOver releases are more stable. The one major downside is that Crossover is not free.
  • PlayOnLinux: PlayOnLinux is completely based on Wine. And provides an easier route for installing and managing applications with Wine. PlayOnLinux is free. It is also available for Mac as PlayOnMac.
  • Bottles: Bottles app got huge popularity recently, because of its ease of use and various other life-saving features. It is available as a flatpak to install on all Linux distributions. You can run Applications and Games inside bottles.
  • ReactOS: ReactOS is an entirely different open-source operating system for running Windows applications. It reuses a considerable amount of codes from Wine. However, this is a project under development for more than a decade and I won’t recommend it.

Purchase CrossOver Through the CodeWeavers Store Today!

Buy CrossOver Mac and CrossOver Linux through the CodeWeavers store. Choose from 12 month and lifetime license plans. Renewals are also available for purchase.

CodeWeavers

Additional Tips on using Wine

Winetricks

This is another important part of using Wine. Winetricks is a helper script to download and install various redistributable runtime libraries needed to run some applications in Wine. These may include replacements for components of Wine using closed-source libraries. Winetricks comes with Wine installation on Ubuntu through the package manager.

For starting winetricks, run this command:

winetricks

If you have installed Wine from Wine official repository, you may need to install winetricks separately.

To do this, open a terminal and enter the following commands:

cd "${HOME}/Downloads"
wget  https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks
chmod +x winetricks

Now open Winetricks with:

./winetricks

Winetricks interface

There are many options for helping you with various tasks.

Installing an Application with Winetricks

If you Install an app from winetricks, it will be installed in a separate wineprefix. Let’s install VLC:

So, select install an app from the options and click OK:

Select the Install an Application option and press OK to install a new application using Winetricks

Now select VLC from this list:

Select an application available from the list to install

It will then begin to download the VLC installation files. And then guide you through the rest of the process. It’s pretty simple.

Install Windows DLL or components and others

You can select a wineprefix from winetricks and install various libraries and components required by the application you want to run and also perform other operations.

Select the Install a Windows DLL or Component option from Winetricks 

And then select the required DLL or component to install:

Select the required DLL from the list

📋

N.B.: If using winetricks seems complicated to you, it’s perfectly okay. I feel the same way too. I always use PlayOnLinux for this reason. PlayOnLinux can do everything you might need to do from winetricks.

For more information, you can check Wine FAQ and Documentation.

I hope you find this complete beginner’s guide to using Wine in Linux helpful. Now you can run Windows programs in Linux without installing a virtual machine or dual booting.

Let us know if you have any questions or opinions in the comment section below.

This is a step-by-step guide to how to install wine on Ubuntu 18.04 LTS.

Not all software supports Ubuntu, Most of them are not available in the Ubuntu software repository or in deb format which is the package format used in Ubuntu. So If you want to install a software that comes in exe or msi format, then you need “Wine Windows Program Loader”.

Wine is an implementation of the Microsoft Windows API that handle Windows programs. With wine you can run windows programs directly on your Ubuntu 18.04 desktop.

To install wine on Ubuntu 18.04, Log into your Ubuntu desktop, open the terminal window and do the following steps:

  1. First, Configure Ubuntu wine repository with following set of commands:

    sudo dpkg --add-architecture i386
    wget -nc https://dl.winehq.org/wine-builds/Release.key
    sudo apt-key add Release.key
    sudo apt-add-repository https://dl.winehq.org/wine-builds/ubuntu/
  2. Next, Update the package repository and install the winehq-stable package:

    sudo apt-get update
    sudo apt-get install --install-recommends winehq-stable
  3. After the installation is finished, run the winecfg command to configure wine:

    winecfg

When you run winecfg command, first it will ask for the confirmation to download necessary packages. This includes wine-mono and Gecko packages. Next, you will get the configuration window.

After the installation is finished, run the winecfg command to configure wine

Under the Applications, Select windows 7 as the windows version and click ok.

The winecfg command also creates the wine configuration directory (.wine) in your home directory (/home/username/.wine).

.wine virtual c drive ubuntu

When a new software is installed, you can find it in the .wine/drive_c/Program Files (or Program Files (x86))folder in your home folder.

Note that, .wine is a hidden folder so you may not see it in the file manager, In the file manager (GUI), you need to choose Show Hidden Files from the menu to see hidden folders.

How to use wine to install windows software on Ubuntu

Let’s install a Windows software on our Ubuntu 18.04 desktop to test the Wine Windows Program Loader. For this example, I am going to install a Chess software called Lucas Chess, but you can install any other software you want.

The point is when you get the windows installer (.exe or .msi), right click on the installer and click “Open With Other Application” if you don’t see the “Wine Windows Program Loader” already.

From the Application List, select “Wine Windows Program Loader”.

How to use wine to install windows software on Ubuntu

You will get the installation wizard in the same way as if you are using Microsoft Windows.

Install Lucas Chess on Ubuntu wine

Wine will also create the launcher icon which you can find in Ubuntu application menu.

The software will be installed to the Program files directory in the Virtual C drive. In this example, Lucas Chess was installed in the .wine/drive_c/Program Files (x86)/LucasChess/.

Ubuntu Wine windows program installation directory

Inside the installation directory, we have the Lucas.exe file that launches the program.

Create a Desktop Launcher

If you can’t find the menu icon to the software, create a text file on your desktop with .desktop extension (e.g. “Lucas Chess.desktop”) and add the following configuration:

[Desktop Entry]
Name=Lucas Chess
Exec=env WINEPREFIX="/home/username/.wine" wine "/home/username/.wine/drive_c/Program Files (x86)/LucasChess/Lucas.exe"
Type=Application
StartupNotify=true
Icon=E12D_Lucas.0

In the configuration, you should replace “Exec=” line accordingly.

  • The “WINEPREFIX=” should be the full path to the .wine hidden folder in your home directory.
  • Next, the wine command should followed by the full path to .exe file in the installation folder.

The “Icon=” should be replaced by the name of the menu icon (You should be able to find icons in your home folder, inside the .local/share/icons/ directory).

To activate the launcher, right click on the desktop file, Click Properties > Permissions and select “Allow executing file as program”.

Create a Desktop Launcher for wine program

Then, double click on the desktop file and click “Trust and Launch”.

Uninstall a Program installed with wine

Just in case you want to uninstall any program, open the Ubuntu terminal and execute:

wine uninstaller

You will get the “Add/Remove Programs” window. Here select the wine program you uninstall and click on the “Modify/Remove” button.

Uninstall a Program installed with wine in Ubuntu 18

Summary

In this tutorial we learned how to run windows program on Ubuntu 18.04 Bionic Beaver with wine windows program loader.

Wine is an open-source implementation of the Windows API that runs on top of the your Ubuntu Linux system. With wine you can install most of the windows software on Ubuntu.

This is a classic article written by Jack Wallen from the Linux.com archives. For more great SysAdmin tips and techniques check out our Essentials of Linux System Administration course!

Back in the mid 90s and early 00s, Linux, being a fledgling operating system, suffered from a severe lack of useful applications. This issue was especially critical in the world of business ─ where Windows desktop applications could make or break productivity. To overcome this weakness, a compatibility layer called WINE was created. The name originally stood for Wine Is Not an Emulator (because everyone mistook the tool for a Windows emulator). The name is now simply Wine.

Effectively, what Wine did was to allow Windows applications to run on the Linux platform. It wasn’t perfect, and the supported apps were limited. If you wanted Notepad, Calculator, or Solitaire…you were good to go.

But then something interesting happened. Over time more and more applications were supported until Wine became a must-have tool for many users and businesses (and especially Linux gamers). To date there are thousands of fully supported applications that now run on Wine (check out the application database for a full list) and that list is ever growing. Granted most of the Wine work is focused on games, but you’ll still find a healthy list of productivity apps available.

You might think, because of the complexity of bringing such a tool to life, that Wine would be complicated to install and use. That assumption would be incorrect. In fact, the developers of Wine have gone out of their way to make the compatibility layer as user-friendly as possible. What exactly does that mean? To make this easier, let’s walk through the process of installing Wine and then installing and running a Windows application with the tool.

I will demonstrate the process on Elementary OS Freya and install the latest version of Wine.

Installation

If you are running an Ubuntu derivative, you’ll find Wine located in the Software Center. Chances are, however, that version is outdated. Because of that, we want to avoid installing the “out of the box” version offered. To do this, we must add the official Wine repository. This can be done one of two ways, via command line or GUI. Since our goal is running Windows applications, let’s use the GUI method.

Here’s how:

  1. Click on the Applications menu

  2. Type software

  3. Click Software & Updates

  4. Click on the Other Software tab

  5. Click Add

  6. Enter ppa:ubuntu-wine/ppa in the APT line section (Figure 2)

  7. Click Add Source

  8. Enter your sudo password

  9. Click Authenticate

  10. Click Close

  11. When prompted, click Reload

  12. Open the Software Center

  13. Search for Wine

  14. Click the Wine entry and then click Install

  15. Allow the installation to complete.

That’s it. Wine is now ready to help you install and run Windows applications. Remember, however, that not every application will work. Most will, but if you’re looking to get your in-house, proprietary solution up and running, you might hit a few snags.

Installing and running an app

Let’s install a very popular programmers notepad—Notepad++. You’ll want to download the file from a location that doesn’t include third-party app install options (which can cause the application installation to fail). To be safe, download the Notepad++ installer from Filehippo. You will find .exe file for Notepad in your Downloads directory. Right-click that file and select Open in Wine Windows Program Loader (Figure 3).

Upon first run, the Wine configuration for ~/.wine will be updated. This can, depending upon the speed of your machine, take a bit of time. Allow this to finish and then the all-too-familiar Windows installation wizard will start up and walk you through the installation of Notepad++.

Click Next and walk through the installation process. When the second screen pops up (Figure 4), you will notice a rather un-Linux Folder path.

Linux doesn’t contain a C drive as does Windows. Is this wrong? No. If you look in the ~/.wine folder, you will notice a folder called drive_c. Within that folder lies three familiar sub-folders:

  • Program Files

  • users

  • windows.

As you might expect, this is your C drive. All of that is to say, leave the Folder path as-is during installation.

You will eventually come to the Choose Components section of the installation (Figure 5). Here you can select options for the installation. If your particular desktop environment allows desktop icons (and that is your preference for launching apps), you might want to select Create Shortcut on Desktop (to make the launching of the newly installed app easier—more on this in a moment).

The installation will complete and present you with the Finish screen. Leave the Run Notepad box checked and click Finish. Notepad++ will run (Figure 1).

What happens, if you didn’t add the app icon to your desktop, when you want to run the software again? This is one issue that can easily trip users up. Remember that Program Files sub-directory? If you venture into that folder, you’ll see a folder for Notepad++ which contains the notepad++.exe file. Guess what? Right-click that file, select Open in Wine Windows Program Loader, and Notepad++ will run.

Notepad++ is a simple example of how Wine works. When you dive into more complicated applications, your results may vary. The best thing to do is to go back to the Wine application database, locate the app you want to install, click on it, and check the current app status. You will find every app lists the version of Wine tested, if it installs, if it runs, and gives it a rating. There are:

  • Platinum: Applications which run flawlessly out of the box.

  • Gold: Applications which run with some modifications necessary.

  • Silver: Applications which run with minor issues that do not affect usage.

You will also find some apps listed as Garbage, which means they won’t install and/or run.

If you have a Windows app that simply doesn’t have a Linux equivalent, never fear ─ Wine is here to assist you. Even though not every Windows app will run under Wine, the collection of apps that do is seriously impressive. And considering most everything we do nowadays is handled within a web browser, with a little help from Wine, you should be covered from every angle.

Ready to continue your Linux journey? Check out our Essentials of Linux System Administration course!

Download Article

How to install Wine and use Windows programs on Linux

Download Article

  • Installing Wine
  • |

  • Setting up Wine
  • |

  • Installing a Program
  • |

  • Q&A
  • |

  • Warnings

Do you want to run a Windows game or app on Linux? Linux is a great operating system, but it doesn’t support many of the programs and games you use on Windows. Luckily, there is Wine, a Windows emulator that can run many Windows programs and games on a Linux computer. This wikiHow guide teaches you how to install and run Wine on a Linux computer.

Things You Should Know

  • Install Wine in the Terminal using «sudo apt install wine64» (64-bit computers) or «sudo apt install wine32» (32-bit computers).
  • Download a Windows «.exe» or «.msi» program and go to the download location by typing «cd ~/Downloads» in the Terminal and pressing «Enter.»
  • Type «wine <name of «.exe» or «.msi» file>» and press «Enter» to install the program with Wine.
  1. Step 1 Open the Terminal.

    Select the Terminal application from your computer’s App Menu or Applications list to do so.

    • On most Linux versions, you can also open the Terminal by pressing Ctrl+ Alt+ T.[1]
    • Some Linux versions also have a command line textbox at the top of the screen.
  2. Step 2 Check your computer's architecture.

    You need to know if you are using a 32-bit or 64-bit version of Linux. Use the following steps to do so:[2]

    • Type lscpu in the Terminal and press Enter.
    • Check if it says «32-bit» or «64-bit» next to «CPU op-mode(s).»

    Advertisement

  3. Step 3 Type sudo apt update and press ↵ Enter.

    This will update the software repository.

  4. Step 4 Enter the command to download and install the 32-bit or 64-bit version of Wine.

    Enter one of the following commands and press Enter to install Wine on a Debian-based Linux distribution, such as Ubuntu or Linux Mint:[3]

    • For 64-bit systems: sudo apt install wine64
    • For 32-bit systems: sudo apt install wine32
    • If you are using Fedora or Redhat, install Wine using kbd sudo dnf install winehq-stable.
  5. Step 5 Type y to confirm the installation.

    When prompted to enter «y» or «n,» press «y» to confirm the installation.

  6. Advertisement

  1. Step 1 Type in winecfg and press ↵ Enter.

    This creates a Windows home directory for Wine. Look for a confirmation message that says something like «created the configuration directory ‘home/name/.wine'».[4]

    • If prompted to install any missing packages here, click Install in the prompt window and wait for the packages to install.
  2. Step 2 Select a Windows version and click Apply.

    Click the «Windows Version» drop-down box at the bottom of the «Wine configuration» window, then click the version of Windows (e.g., Windows10) that you want to use. Then click Apply in the lower-right corner.

  3. Step 3 Click OK.

    This button is at the bottom of the window. Clicking it closes the Window.

  4. Advertisement

  1. Step 1 Download a Windows program in ".exe" or ".msi" format.

    Download a Windows install file in an «.exe» or «.msi» version of the program that you want to use on Linux (e.g., Notepad++) and download it from the official website. It will download to your Linux «Downloads» folder. Once you’ve done this, you can move on to installing it.

    • You can see a comprehensive list of Wine-compatible programs on Wine’s website.
  2. Step 2 Type ~/Downloads and press ↵ Enter.

    This switches to the Downloads folder in the Terminal where the downloaded Windows application installer is downloaded.

  3. Step 3 Type wine <installer file name> and press ↵ Enter.» src=»https://www.wikihow.com/images/thumb/8/85/Use-Wine-on-Linux-Step-11-Version-3.jpg/v4-460px-Use-Wine-on-Linux-Step-11-Version-3.jpg» width=»460″ height=»345″ loading=»lazy»></p>
<div class= Картинка с сайта: www.wikihow.com

This will open the installer file using the Wine Windows program loader.[5]

  • Alternatively, you can right-click the «.exe» or «.msi» file in your Downloads folder and click Open with Wine Windows Program Loader. If this option does not appear, use the Terminal command instead.
  • Step 4 Follow the instructions to complete the installation.

    The Windows installation window will appear. Follow the instructions in the installation wizard to complete the installation.

  • Step 5 Open Windows applications.

    You can open Windows applications installed using Wine by clicking their icon in the Apps Menu or Apps list, the same as you would any Linux application. This will open the application using the Wine Windows Program Loader.

    • Alternatively, you can navigate to the location of the Windows executable file in the virtual «C:» drive and run the program by typing wine <executable file name> and pressing Enter. You can navigate to the folder Windows programs are installed in on the virtual «C:» drive by typing cd ~/.wine/drive_c/Program\ Files and pressing Enter. Then enter the program folder with the executable file by typing cd "<folder name>" with the folder name in quotes and press Enter. Then enter the command to run the executable file in Wine.
  • Advertisement

    Add New Question

    • Question

      What is Wine? Why do you use Wine? Where do I use Wine?

      77Ecrivan

      Community Answer

      Wine is a compatibility layer that allows you to run Windows software on systems such as Linux, MacOS/OSX and BSD. In the case of GNU/Linux, it’s obvious Linux distributions are not as widely supported as Windows. For this reason, it is incredibly convenient to be able to run Windows software in the way that Wine lets you.

    • Question

      How can I run .jar files in Linux Mint?

      First, fire up Terminal and type in «sudo apt install default-jre.» Once downloaded, navigate to the folder that your .jar file is in by executing «cd.» Once there, type in «java -jar JavaFileNameHere.jar» and you’re done!

    • Question

      Can I run any Windows based program through Wine on Linux?

      No, not every Windows based application can run through Wine. You can go to Wine AppDB to see the list of Windows application that can run well with Wine.

    See more answers

    Ask a Question

    200 characters left

    Include your email address to get a message when this question is answered.

    Submit

    Advertisement

    Thanks for submitting a tip for review!

    • Wine is a comprehensive compatibility program, but it will still have trouble running high-end PC games and programs at a normal frame rate.

    Advertisement

    About This Article

    Thanks to all authors for creating a page that has been read 801,534 times.

    Is this article up to date?

    Понравилась статья? Поделить с друзьями:
    0 0 голоса
    Рейтинг статьи
    Подписаться
    Уведомить о
    guest

    0 комментариев
    Старые
    Новые Популярные
    Межтекстовые Отзывы
    Посмотреть все комментарии
  • Microsoft windows приложение не отвечает возможно что приложение ответит если подождать что делать
  • Где находится просмотрщик изображений windows 10
  • Владельцы устройства windows 10
  • C windows system32 spool servers
  • Windows forms контекстное меню