Wednesday, January 20, 2010

VLC media player installation in Fedora 12

This article of mine is conceptually unique , in the aspect that I am not focussing on any conceptual view , by theory . Let's try to understand package management in RPM based Linux installations, to get an overview and understanding of package management in LINUX.

Let me also try to simplify the process to remove the myth about the difficulty in LINUX application installation procedure .

Y package management ?
Package management is basically used to customise an installation , after it has been installed . Administrators and users , always get a basic system installed and customise it as per their requirement. 

Anectode : We have a cup of black tea with us . It is our choice to either add milk or any other flavour of our choice. This adds flexibility to the OS installation.

What is RPM package manager ?

 RPM - RedHat Package Manager, is the environment , which provides safe installation of LINUX applications , in the form of packages , which can be easily added , created or upgraded . Today, if we are easily , able to install packages without manually resolving dependencies ,we must be thanking the developers of such package management utilities.

Today RPM is also called as "RPM package manager" as a recursive acronym.

The local RPM database (1)

Working behind the scenes of the package manager is the RPM database, stored in /var/lib/rpm. It uses Berkeley DB as its back-end. It consists of a single database (Packages) containing all of the meta information of the installed rpms. Multiple databases are created for indexing purposes, replicating data to speed up queries. The database is used to keep track of all files that are changed and created when a user (using RPM) installs a package, thus enabling the user (via RPM) to reverse the changes and remove the package later. If the database gets corrupted (which is possible if the RPM client is killed), the index databases can be recreated with the rpm --rebuilddb command.

What is a package ?

A package is an archive of related files to any application or program. These also include special metadata , to support the installation of the application  , along with the installation binaries (like RPM files) .

Let us consider , a simple example of installing vlc media player for FEDORA 12 . Installing any other package , follows a very similar suite.

1) su root
2) rpm -ivh
3) yum install vlc
The first command is to run the session as a previledged user , to administer the 
installations on the machine. 
The second command , installs the specified RPM (in this case a URL) , and displays 
the progress of installations , which  we can observe .
The third command adds some flavour , to install dependencies associated with the related package.
Easy is'nt it ? 
Spread the LINUX flavour by exploring various installations. 
As usual feel free to comment.

Intelligent Compiling Utility for Linux - make

This post is basically to introduce a simple introduction to the make utility of UNIX.

The make utility is a software engineering tool for managing and maintaining computer programs. Make provides most help when the program consists of many component files. As the number of files in the program increases so to does the compile time, complexity of compilation command and the likelihood of human error when entering command lines, i.e. typos and missing file names.

By creating a descriptor file containing dependency rules, macros and suffix rules, you can instruct make to automatically rebuild your program whenever one of the program's component files is modified. Make is smart enough to only recompile the files that were affected by changes thus saving compile time.

For complete documentation , refer :