Wibbly Stuff

Installing Applications in Linux

As a new Linux user, in the beginning I didn't know which are the installer files like .exe in windows. At first I searched for latest version of firefox in its website and I end up with a .tar.bz2 archive. What a pity, double clicking it only opened it in archive manager, not installed it. Later I knew that it was the source code. Not any installer. So any new Linux user will surely face problems with installation of softwares. Here I mention 5 ways to install applications in Linux.

In some examples, I take "vlc" as our application to be installed.

1.Command Line Way

You should know the package name to install via terminal. Also, the software should be present in the repository. Instruction to add repository should be given in the product's site. After you have done, open the 'Terminal' and type,

For Ubuntu & other APT & Debian based distributions,
sudo apt-get update
sudo apt-get install vlc

For Fedora & other YUM & RPM based distributions,
sudo yum install vlc

2.Graphical Way

First, you should have a package manager like Synaptic(gnome), Adept(KDE) or PackageKit. Search the application name in the Package Manager, mark it for installation and click apply.

Above two processes are basically same. The software will be automatically downloaded and installed with all its dependencies. The downloaded files are stored in /var/cache/apt. You can clean the cache by the command,Copy to clipboardCode:sudo apt-get cleanI would recommend you to take a backup first. You can try APTonCD for this purpose.

3.Use Previously Packaged Applications

This is the easiest way. If you use Ubuntu or Linux Mint, download a .deb file and double click it to install. In Fedora, you will find .rpm packages. Assume it is in Downloads folder in Home directory. You can also type,

sudo dpkg -i ~/Downloads/vlc.deb
sudo apt-get -f install

or

sudo yum localinstall --nogpgcheck ~/Downloads/vlc.rpm

You can also use "*" in place of the file name to install multiple files.

4.Installing Packages meant for other Distributions/OS

Sometimes, you don't get a .deb package, but find a .rpm package. You can use "alien" to convert it to .deb. It also supports many other formats like solaris .pkg, slackware .tgz etc. To convert a file to .deb, in terminal, type,

sudo alien -d filename

Similarly to convert a file to rpm, type,

sudo alien -r filename

There are Linux alternatives for almost all Windows programs. But if you still need one to install, install "wine". Then just double click .exe files or open with "Wine Windows Program Loader" to install it.

5.Installing Packages from Source

You may only get the source file which would be a .tar.gz, .tar.bz2 or any other archive. First you have to extract them. Then make it the current directory by typing,

cd path

Then to configure and compile, type,

sudo ./configure



sudo make

Then to install, type,

sudo make install

To clean the temporary files, type,

sudo clean install

Many times, it cannot work because of unmet dependencies. The dependencies will be mentioned. You have to first install them via any of the above processes. To compile from source, you need to have "build-essentials" installed.