How To Install WineHQ on Rocky Linux 9

In this article, we want to teach you How To Install WineHQ or Wine on Rocky Linux 9.

At times, a Mac or Linux user may wonder if they would be able to run Windows applications and software on their operating system, without installing a copy of the Windows OS on their computer. WineHQ, a free software, and a program loader do exactly this! It enables Linux, Mac, FreeBSD, and Solaris users to run Windows applications on their system, without running a copy of Microsoft Windows.

Steps To Install WineHQ on Rocky Linux 9

To complete this guide, you must log in to your server as a non-root user with sudo privileges. To do this, you can follow our guide the Initial Server Setup with Rocky Linux 9.

Install Wine on Rocky Linux 9

By default, the Wine repository is not available in the default Rocky Linux repository. You need to build it from the source. First, update your local package index with the following command:

sudo dnf update -y

Install Epel Repository

Then, you need to install the Epel release on your server:

sudo dnf install epel-release -y

Enable PowerTools (crb) on Rocky Linux 9

Here you need to enable the power tools with the following command:

sudo dnf config-manager --set-enabled crb

Install Development Tools

Next, install the development tools that you need to build the Wine Source code on your Rocky Linux 9 with the command below:

sudo dnf groupinstall 'Development Tools' -y

Also, you need to install the required packages on your server with the following command:

sudo dnf -y install gcc libX11-devel freetype-devel zlib-devel \  libxcb-devel libxslt-devel libgcrypt-devel libxml2-devel \  gnutls-devel libpng-devel libjpeg-turbo-devel \  libtiff-devel dbus-devel fontconfig-devel

Download and Build WineHQ From Source

Now you need to visit the WineHQ Downloads Page to copy the link address of the latest release and use the wget command to download it from the source:

sudo wget

Extract your downloaded file with the following command:

sudo tar xvf wine-*.tar.xz

Then, switch to your Wine directory on Rocky Linux 9:

cd wine-*/

At this point, you can configure and install Wine with the following commands:

sudo ./configure --enable-win64
sudo make install

This will take some time to complete.

Verify Wine Installation

Verify your Wine installation on Rocky Linux 9 by checking its version:

wine64 --version

Finally, you can start installing Windows programs on your Rocky Linux.

The syntax of it is like this:

wine64 ./path-to-your file.exe


At this point, you have learned to Install WineHQ or Wine on Rocky Linux 9.

Hope you enjoy it.

You may be like these articles:

Set up NTP Server and Client on Rocky Linux 9

How To Install CSF Firewall on Rocky Linux 9

Newsletter Updates

Enter your email address below and subscribe to our newsletter

Stay informed and not overwhelmed, subscribe now!