Saturday 7 September 2013

How to Install Packages in Ubuntu

How to install .RPM file on ubuntu
Ubuntu directelly install .DEB file so you can use alien to convert it to your preferred package format and install it. Alien is available in the Ubuntu repository so you can install it by using the following command
$ sudo apt-get install alien
To convert an rpm file to deb, use the following command
$ alien -d -k package.rpm
Where package.rpm is the rpm package that you want to convert. The ‘-k’  option is to tell alien to keep the same version number on the resulting .deb as the rpm file.
Alien can also convert .deb packages to .rpm and the command to do that is
$ alien -r package.deb
How to insatll the TAR.GZ packages
extract tar.gz packages using this command
$ tar -zxvf filename
we now need to go into the new directory, so use the cd command:
cd directory
This is where things will differ. Some packages will have an INSTALL or README file which will contain installation instructions. use "ls" to see if the software has an install or readme file. If it does have one, you can use the "more" command to read it, like so:
more INSTALL
Generally, the final 3 stages are as follows:
- Configure the installation
- Compile the software
- Install the binaries
The pre-installation configuration is done by executing ./configure:
./configure
This will perform some requirements testing on your system, and create a "Makefile" which will
explain to the "make" utility how the software should be compiled The next stage is to compile the
software, this is done using "make". When you run "make" it will read the instructions in the
Makefile and build the application binaries.
Make
The final stage is to install these binaries, ie, copy them to a more permanent location
sudo make install
How to insatll the TAR.BZ2 packages
extract tar.bz2 packages using this command
tar xjf file.tar.bz2
installation using the following com