1. Home
  2. Linux
  3. Convert debian programs to redhat on linux

How To Convert Debian Programs To Redhat On Linux

When it comes to the binary package formats, Debian is king. Out of all the software out there, the DEB file format enjoys the most attention from developers. As a result, Linux operating systems based on Debian usually get new stuff before anyone else. Steam, Spotify, Google Chrome, Skype, and the list goes on. Redhat-based Linux operating systems enjoy a similar kind of attention from developers, but not nearly as much as Debian ones. It is because of this, many turn to finding ways to de-compile, and reverse engineer Debian programs. There are many different ways to do this, but by far the best way to convert a Debian program to Redhat on Linux is by using the Alien package converter.


Alien is a program that is written with Perl programming language. In order to run this terminal app on your PC, you’ll first need to install various Perl packages. On some Linux distributions, Pearl may already be installed. In this guide, we’ll be going over how to convert Debian packages to the Redhat package format. It is because of this, we’ll only go over how to get Pearl on Fedora, and Open SUSE.

To check and see if you’ve already got the tools on your Linux install to run Alien, open a terminal window and do the following:

perl --help

Running this command on a Linux PC that has the Pearl tools already installed and ready to go will show a help prompt. This prompt details everything the user needs to know about the language, how to use it and etc. If nothing happens when you run this command, the Pearl tools are not installed.

Install Perl for Fedora

sudo dnf install perl-core

Install Perl for OpenSUSE

Perl is available in the OBS. Go here, and click the “Direct Install” button to get it working.

Building Alien

Building this program is quite simple, and only takes three steps. To start off, grab the source code from official Source Forge page. Then, open a terminal window. In this terminal, do the following actions.

First, go to the download directory where the Alien source code is.

cd ~/Downloads

Then, extract the contents of the archive, with the tar command.

tar xvfJ alien_8.95.tar.xz

When the tar archive finishes, enter the code directory using the cd command.

cd alien_8.95

First, use Perl to create a MakeFile. This is important, because without this file, your PC will have no idea how to build the software.

perl Makefile.PL

Now, use the newly created make file to “make” the software.


Alien is built and ready to use. Now all that’s left is to move the software from the source code directory to the correct place on your PC. This is done with the “make install” command. Unlike the other two commands, make install MUST be run with sudo privileges. This is because it will be moving software to important, system directories.

sudo make install

When the make install command finishes, run Alien via the terminal with: alien

Converting Packages From Debian To Redhat

To convert a package from the Debian format to the Redhat format, first download a package. As DEB’s are the most popular Linux binary format, they shouldn’t be too hard to find. Not sure what to do? Check out our list on how to find missing software on Ubuntu.

When you’ve got a Debian package file, open a terminal. Then, cd to the downloads folder.

cd ~/Downloads

Convert the program from DEB to RPM with the -r switch.

sudo alien -r *.deb

Running this command will most likely result in Alien generating an RPM package. Please keep in mind that this may not always work. Some Debian packages have a lot of specialized files in them, and as a result may refuse to convert.

Other Alien Features

The Alien package converter can do more than convert from Debian to RPM. Here’s how to use them.


The -d switch, users can convert an RPM to a Debian file.

sudo alien -d file.rpm

Convert To Slackware package

Using the -t switch, users can convert any package to a Slackware Linux package.

sudo alien -t file

Convert To Solaris package

Easily convert any package format with Alien to the Solaris package format, using the -p switch.

sudo alien -p file

Fix Permissions

Sometimes converting from one binary package format to another can mess up individual permissions. It is because of this, Alien has a feature that can fix different permission issues. Use the –fixperms flag to iron out errors.

sudo alien file --fixperms

Test Generated Packages

It’s possible to test new packages generated with Alien. To test a generated package, use the –test flag.

sudo alien file --test

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.