Creating deb Packages in Ubuntu from tar.bz is possible using “alien” command. Alien command converts an RPM or source package files into a Debian package file or Alien can install an RPM file directly. Creating deb packages with alien is not recommended to replace important system packages, like init, libc, or other things that are essential for the functioning of your system, because some distributions setup these packages differently. But for other packages that doesn’t available yet in Ubuntu or debian you can create deb packages with this alien command.
Before creating deb packages you need to install alien, if you haven’t install it yet, you can grab the following script and run in from your terminal:
sudo apt-get install alien
It will took a while to finished, after it finished you will ready creating deb packages from tar.bz or RPM files.
Creating deb Packages With Alien
Creating deb packages with Alien you can use this following format:
alien [--to-deb|-d] [options] file [...] For example: alien --to-deb -V file.tar.bz #Will create file.deb with verbose alien -d -V file.tar.bz #Will create file.deb with verbose
Beside converting from tar.bz file, alien could convert from rpm packages too.
alien --to-deb -V package.rpm
It is also work with multiple options:
alien --to-deb --to-rpm --to-tgz --to-slp bar.rpm
That command will create 3 package format, deb package, rpm package and tgz package.
This is not the recommended way to install software packages in Ubuntu. If at all possible, install packages from Ubuntu’s repositories using Add/Remove, apt-get, or the Synaptic Package Manager. Package dependency conflicts may occur when attempting to install RPM packages. But if you have no other choice you can use Alien with cautions. And Don’t run alien on tar files with source code in them, unless you want this source code to be installed in your root directory when you install the package!
Creating deb packages with alien manual