On Arch Linux, the installation of packages or applications can be done in various ways because there are different package installers available for that. Usually, the default package manager has the applications packages but some applications are still missing so in that case other package installers are used. Usually, every software has its deb file or source file on its official website which can be used to install it. On Arch Linux you cannot use the deb file directly to install an application, instead, you need to convert it to another format (zst).
Outline:
How to Install Deb File on Arch Linux
To install the deb file on Arch there is only one way and that is by using the debtap utility, however, you will see that some blogs have stated the method of using the dpkg package installer which not only fails but can also break the system. So to install a deb file on Arch Linux you need to install debtap first which can only be installed using the AUR repository here I have used yay AUR helper:
After this debtap utility is installed on Arch Linux you need to first update the database for the debtap tool as it will ensure that the package installation is successful and fully compatible with your system. Otherwise, you will get the error while trying to convert a deb file into zst format on Arch as in the image below:
To update the database for debtap use the update flag as in the command below:
Now convert the deb file to zst format, here for illustration I have converted the deb file for Discord by just using the debtap command:
During the conversion the system will ask about the packager’s name and its license, you can add their name and the license in case you’re installing an application that requires a license for activation. Otherwise, you can leave it blank and prompt the process by hitting enter:
During the conversion, the debtap utility will ask about editing the PKGINFO and INSTALL files of the application, as both of these files contain important information about the data and instructions for installation.
The PKGINFO file contains the metadata which includes the package description its version, its dependencies, and more. The INSTALL file on the other hand contains the commands that are to be executed before and after the package installation or removal. You can ignore this message and prompt the file creation process by pressing enter:
Once the file is created all you need is to install the application using the Arch default package installer along with the upgrade flag and for that execute:
Once the installation is complete you can launch the respective application in my case it’s Discord so for that:
Note: While installing the deb file through debtap you ought to have ample space in your system as in my case Discord needed 15GB of my system space which is quite huge. Moreover, you might not be able to install every application through a deb file as there might be some issues with the conversions and dependencies.
Can I Install Deb File on Arch Using dpkg
Arch Linux only allows the dpkg package installer to create or modify the deb file so you cannot install deb files on Arch using dpkg. To support this argument, I have demonstrated the issues that are encountered while trying to achieve that. First, I have installed the dpkg on Arch using Pacman:
Now as in the image below, there is a clear instruction stating that this can break the system and can only be used for creating or modifying the deb files:
Next, I tried installing the deb file for Discord, and it gave the error of missing dependencies which should be manually installed. However, I have tried installing the missing dependencies, but I have encountered the error of no installation candidate.
Next, I have tried installing deb file for Google Earth and here other than the dependencies’ error it has given me the error of dpkg is not installed. I have also tried updating the dpkg package but still it is giving the same error:
Note: Instead of trying to install packages using their deb file on Arch Linux it is always recommended to use the other package installers because deb files are not supported directly on Arch.
Conclusion
To install the Deb package on Arch there is only one way which is by using the debtap utility which is used to convert the zst file and then through Pacman, the respective application can be installed. However, not every application on Arch can be installed through it as there may be broken packages in the file due to conversion.
I’m Aaliyan javaid, an electrical engineer and a passionate tech enthusiast. I have been working with embedded systems, programming, and Linux operating systems for over 2 years. I love to explore new technologies and share my knowledge and experience with others.