Using Wine 8.0 on Debian Linux unlocks a range of functionalities, allowing you to run Windows applications seamlessly. Here’s a quick overview of Wine’s features and benefits with the release of Wine 8.0:
- PE Modules: All modules are now converted to PE format, enabling better copy protection and support for 32-bit applications on 64-bit hosts.
- WoW64: Enhanced support allows 32-bit PE modules to call 64-bit Unix libraries, with an experimental mode miming Windows WoW64.
- Graphics: A new “Light” theme, implementation of the Print Processor architecture, and added support for effects in Direct2D enhance the visual and functional aspects.
- Direct3D: Performance boosts through optimizations, streaming map acceleration, and a new WINE_D3D_CONFIG environment variable.
- Audio/Video: Improved content type resolution and rate control, alongside support for Enhanced Video Renderer, ensures better media handling.
- Media Foundation: Further enhancements in content type resolution and rate control.
- Input Devices: Better controller hotplug support, force feedback effects, and enhanced compatibility with various controllers.
- Internationalization: Introduction of a proper locale database and support for high Unicode plane characters.
- Text and Fonts: Font linking enabled for most system fonts, improving text rendering.
- Kernel: Implementation of the ApiSetSchema database reduces disk space and address space usage.
These enhancements make Wine 8.0 a robust solution for integrating Windows applications into your Debian environment. With this groundwork laid, let’s dive into the technical steps to install and configure Wine on your Debian system.
Wine 8.0 Pre-installation Steps
Updating Your Debian Before Wine 8.0 Installation
Update your system to ensure a smooth and successful installation. Use the following command:
sudo apt update && sudo apt upgrade
The command sudo apt update refreshes your system’s local repository database to get the latest metadata from the Debian repositories. The command sudo apt upgrade then upgrades the currently installed packages to their newest versions.
Install Initial Required Packages For Wine 8.0
Make sure to install a few essential packages that aid the installation process:
sudo apt install software-properties-common apt-transport-https curl -y
This command installs software-properties-common (for adding and removing PPAs) and apt-transport-https (allowing apt to retrieve data using HTTPS).
Enabling 32-bit Support (Optional)
A lot of Windows applications, especially games, use a 32-bit architecture. To maximize compatibility with these applications, enable 32-bit support on your system:
sudo dpkg --add-architecture i386
This command lets your system recognize i386 packages, allowing you to install 32-bit software. Regardless of whether you have a low-end system wanting to play classic 32-bit games or a high-end setup, this feature broadens your software compatibility.
Import WineHQ GPG Key & Repository
Prepare to install Wine by importing a GPG key, which verifies that the software you install is genuine and untouched, and by adding the WineHQ repository containing the installation packages.
First, import the GPG key with this command:
curl -fSsL https://dl.winehq.org/wine-builds/winehq.key | gpg --dearmor | sudo tee /usr/share/keyrings/winehq.gpg > /dev/null
Then, add the WineHQ APT repository:
echo deb [signed-by=/usr/share/keyrings/winehq.gpg] http://dl.winehq.org/wine-builds/debian/ $(lsb_release -cs) main | sudo tee /etc/apt/sources.list.d/winehq.list
This command creates a file named winehq.list in the /etc/apt/sources.list.d/ directory. This file tells our system where to locate the Wine packages. The echo command displays the text line, and the tee command saves this display to the file.
After you add the repository, update your local package database again:
sudo apt update
Select Wine 8.0 Version to Install
Now that our system is primed and ready, let’s focus on our main goal: installing Wine. We have three options, each catering to different user needs.
Option 1: Installing Wine 8.0 Stable Release
The stable release of Wine balances recent updates and reliable functionality, making it a safe choice for most users. To install this version, enter the following command:
sudo apt install winehq-stable --install-recommends
This command downloads and installs the winehq-stable and recommended packages for optimal performance.
To verify the installation and see the version you’ve installed, type:
wine --version
If you prefer a time-tested version of Wine, you can only install the default repository’s 64-bit version:
sudo apt install wine64
If you enabled 32-bit support in the earlier steps, you could install both the 64-bit and 32-bit versions with the following:
sudo apt install wine64 wine32
Option 2: Install Wine Staging Release
If you like staying on the cutting edge of software developments, the WineHQ Staging Release is for you. This version gives you features almost ready for broad use, placing it a step ahead of the stable release.
To install the Wine-Staging Release, type:
sudo apt install --install-recommends winehq-staging
After you install, verify the version and ensure successful installation with:
wine --version
Option 3: Install Wine Development Release
The WineHQ Development Release provides a glimpse into upcoming features and improvements. However, remember that this version may have bugs or be less stable. We mainly recommend it for seasoned users or developers.
To install the Wine Development Release, input:
sudo apt install --install-recommends winehq-devel -y
To confirm your installation and view the installed version, type:
wine --version
Finalize Wine 8.0 Installation
Congratulations! You’ve installed WineHQ on your Debian system. Now, let’s ensure everything is set up correctly. Run the winecfg
command in the terminal. This command sets up essential environments for Wine, including Mono, which allows .NET applications to run on Linux.
Start the Wine configuration with this command:
winecfg
A prompt will ask for your permission to install the necessary components. Click “Install.” After the installation, the Wine configuration dialogue box will open. Here, you can adjust Wine’s settings.
Most users will find the default settings adequate. By default, Wine mimics the Windows 7 environment. You can change this to a different version, like Windows 10. However, as of this writing, Wine doesn’t support Windows 11.
After adjusting the settings, close the dialogue box to save them.
Optional: Install Optional Wine Enhancements
With your Wine installation in place, you might want to explore optional enhancements to optimize the experience. One such tool is winetricks, designed to streamline the installation of specific libraries and applications for better compatibility with Windows software.
To get winetricks, enter:
sudo apt install winetricks
Use winetricks to add Windows components that are not included in Wine. For example, to get a complete set of 32-bit Microsoft fonts, use:
winetricks allfonts
Or locate the application user interface and launch it: Activities > Show Applications > Winetricks
Example: Install NotePAD++ on Debian with Wine 8.0
Wine makes it simple if you’re looking to run Windows applications on your Debian system. One popular example is Notepad++, a widely used free source code editor and a solid alternative to the native Notepad in Windows. Here’s how you can install and run Notepad++ using Wine:
- Download the Notepad++ Installer: Go to the official website and download the Notepad++ installation executable file (.exe).
- Install with Wine: Find the .exe file in your directory after downloading. Right-click the file, choose “Open With” or “Open With Other Application,” and then pick Wine. This action tells your Linux system to use Wine to run the .exe file, allowing you to install Notepad++ as if you were on a Windows machine.
Click the Notepad++ application icon. It will open like on a Windows system, showcasing Wine’s capability.
Remember, this installation method using Wine isn’t exclusive to Notepad++. You can use it for many other Windows applications. With Wine, you bridge the gap between Linux and Windows, broadening your software options.
Additional Wine Commands
Configure Wine for 32-bit Applications
Wine can run both 64-bit and 32-bit Windows applications. However, you must adjust Wine to run older 32-bit software.
To configure Wine for 32-bit, change two environment variables: WINEARCH and WINEPREFIX. Set WINEARCH to “win32” to indicate Wine will run 32-bit apps. Set WINEPREFIX to a directory other than the default ~/.wine.
As explained above, set WINEARCH with this command:
export WINEARCH=win32
Create a separate directory for 32-bit with this command:
export WINEPREFIX=~/.wine32
Now, initialize the new 32-bit Wine setup:
winecfg
This command opens the Wine configuration, where you can adjust settings for 32-bit apps.
Operating Wine From Terminal
Operating Wine from the terminal is advantageous, offering you greater control over the software you’re running. Here, I’ll walk you through some of the most commonly used Wine commands and how to use them.
The most elementary Wine command is, simply, wine
. This command allows you to run Windows applications directly from the terminal. All you need to do is type wine
followed by the path to the .exe file you wish to run.
For example:
wine /path/to/program.exe
The winecfg
command opens the Wine configuration dialogue box where you can modify settings such as the Windows version, audio, and graphics.
Example:
winecfg
The regedit
command lets you access the Wine registry editor, which stores configuration settings for Wine and the Windows applications you’re running.
Example:
wine regedit
The winetricks
command is a valuable tool for installing additional components and libraries not included initially with Wine.
Example:
winetricks allfonts
The winepath
command assists in converting Windows-style paths to Unix-style paths and vice versa.
Example:
winepath -w /unix/path
The wineserver
command, while rarely used, can come in handy for debugging or troubleshooting.
Example:
wineserver -k
Update Wine 8.0
To keep Wine updated with the latest version, you’ll need to use the sudo apt upgrade
and sudo apt update
commands:
sudo apt upgrade && sudo apt update
Remove Wine 8.0
If the need arises to uninstall Wine from your system, you have to use specific commands based on the version you have installed. Here are the commands for removing each version:
For WineHQ Stable Release:
sudo apt remove winehq-stable
Staging Release:
sudo apt remove winehq-staging
For WineHQ Development Release:
sudo apt remove winehq-devel
Once the specific version of Wine has been removed from your system, you can then proceed to delete the repository file:
sudo rm /etc/apt/sources.list.d/winehq.list
For those who have removed the WineHQ repository, it is also advisable to remove the associated GPG key:
sudo rm /usr/share/keyrings/winehq.gpg
If Wine was installed from the default Debian repository, a different command is required for its removal:
sudo apt remove wine32 wine64
Closing Thoughts
The path to successfully installing and utilizing Wine 8.0 with the WineHQ repository on a Debian Linux system can seem intricate and overwhelming at first glance. Yet, through the process we’ve walked through, we’ve seen that it’s not as daunting as it might initially appear. Each command, each step in the process, has a purpose and contributes to creating an environment where Windows applications can run smoothly on your Linux system. From configuring Wine to handle 32-bit applications to running applications using Wine from the terminal to updating and managing Wine installations – each action you’ve learned to perform plays an integral part in creating an efficient, flexible workspace for your cross-platform needs.
Unfortunately, the described procedure on my Debian 11 leads to a lot of unmet dependencies:
The following packages have unmet dependencies:
dbus-user-session: Depends on: dbus (>= 1.12.28-0+deb11u1), Depends on: libpam-systemd but it will not be installed, Depends on: systemd, Recommends: systemd-sysv
evince: Depends on: libevdocument3-4 (= 3.38.2-1) but it will not be installed, Depends on: libevview3-3 (= 3.38.2-1) but it will not be installed, Depends on: libgnome-desktop-3-19 (>= 3.17.92) but it will not be installed, Depends on: libnautilus-extension1a (>= 3.28) but it will not be installed
libcurl3-gnutls: Depends on: libgssapi-krb5-2 (>= 1.17) but it will not be installed
libdbus-1-3:i386: Depends on: libsystemd0
, Recommends: dbus
libgtk-3-0: Depends on: libcolord2 (>= 0.1.10) but it will not be installed, Depends on: libcups2 (>= 1.7.0) but it will not be installed, Depends on: librest-0.7-0 (>= 0.7) but it will not be installed, Recommends: libgtk-3-bin
libneon27-gnutls: Depends on: libgssapi-krb5-2 (>= 1.17) but it will not be installed
libpulse0:i386: Depends on: libsystemd0
librdf0: Depends on: librasqal3 (>= 0.9.31) but it will not be installed
libsoup2.4-1: Depends on: libgssapi-krb5-2 (>= 1.17) but it will not be installed
libwebkit2gtk-4.0-37: Depends on: gstreamer1.0-plugins-good but it will not be installed, Depends on: libgstreamer-gl1.0-0 (>= 1.14.0) but it will not be installed, Depends on: libmanette-0.2-0 (>= 0.1.2) but it will not be installed, Recommends: gstreamer1.0-gl but it will not be installed, Recommends: xdg-desktop-portal-gtk, Recommends: gstreamer1.0-libav but it will not be installed, Recommends: gstreamer1.0-plugins-bad but it will not be installed
yelp: Depends on: libyelp0 (= 3.38.3-1) but it will not be installed, Depends on: python3-distro but it will not be installed
E: Error: Interruptions caused by pkgProblemResolver::Resolve; this could be caused by held packages.
Hi,
The steps described in my guide may not work perfectly on your Debian 11 system due to unmet dependencies. Here’s a simplified solution:
1. Update your package list:
sudo apt update
2. Try to install the packages with aptitude, which handles dependencies better:
sudo apt install aptitude
sudo aptitude install dbus-user-session evince libcurl3-gnutls libdbus-1-3:i386 libgtk-3-0 libneon27-gnutls libpulse0:i386 librdf0 libsoup2.4-1 libwebkit2gtk-4.0-37 yelp
Which version of Wine are you trying to install?