What is Relink? 

Relink is a great Unix implementation, to make your life easier when it comes down to Unix software installation. We will give you a few reasons why you should try it. All you need is a Unix system with Perl 5.6 or newer.

Tired of Packaging Systems?

Relink is an invitation for you to stop worring about packages. Some packaging systems are very good, some not. Some will leave directories all over your drive, after uninstallation or upgrade. Some will have bad written scriptlets. Some will be *VERY* incompatible or uninstallable under its own distribution version cycle.

Anyways, you can even use a RPM to install on! Relocation the package to /app/name-1.0

rpm -ivh package.rpm --relocate\ /usr=/com/app/package-1.0 --bareloc


Or even decompress a tarball compiled!

tar -zxvf tarball.compiled.tar.gz -C /app/compiled-name


Tarballs work everywhere

Without doubt, the tarball sources are the ones always prone to work in every *nix system. You compile your own applications, optimized for your machine instructions and performance, and fitting your current *nix configuration.
But there is a price... Uninstallation can drive an 'obssessed clean' user go mad. The "make install" command fills your /usr/local (or whatever the prefix you chose) throughout the several subdirectories, mixing all programs data into a single entire directory. 

Most times , "make uninstall" will not remove 100% of the crap you installed. And for that, you need to keep your sources compiled in the drive, wasting precious disk space. 

Relink COMES IN!

This is where relink comes in. If you are thinking compiling is fun and a didactic process, it will be even more with Relink.

Relink will create a separate directory for each application, and make them fully usable and deletable, providing the most clean machine, in terms of organization. 
Relink will link or relink all files from its application directory to a global virtual application directory.

See how it's easy: For example...

tar -zxvf crap-1.0.3.tar.gz

cd crap-1.0.3



make install


That is it!

your application is now in /app/crap-1.0.3

and will be activated from /vapp

as you noticed, a symbolic link to /a/app and /a/vapp

It's all here....

/a/app-----------(where your programs are stored)
/a/vapp - ----- (where your programs are ran from - symlinks)
/a/rdb/rdb.dat--(the database file)
/a/app/crap-1.0.3--(the actual dir of your program)
/app---------(makes your life easier)
/vapp-------(makes your life easier) 

The vapp dir (Virtual Application) is the directory that will provide the links distributed in their respective directories, bin, etc, lib, share, include...

Uninstalling your Application

This is the funniest part. It was never simples as this. SIMPLY DELETE your application dir, and RELINK.

Let's remove the crap, installed above.

cd /app

rm -rf crap-1.0.3


and it's DONE! Not a single trace of the program onto the drive! Now, how would you know if "make uninstall" would do it?

What If I screw up my /vapp directory or the database?

Oh you can do that at any time! :-) 
It is never work, unless you're on a RPM based system or other package management!

If you screw the whole thing, deleted files from /vapp, you can anytime do:

relink --init

Everything is right back there! Still running! The database was WIPED and RECONSTRUCTED in seconds!!!