| ryah ( @ 2009-06-16 13:44:00 |
tip
Software you work with is best installed in your home directory. I install them in
The advantage of this is that one can have many versions installed at once. (For example, many versions of Ruby.) Also, the software can be uninstalled with a simple
Software you work with is best installed in your home directory. I install them in
~/local/software_name-version. This is usually done with a command like./configure --prefix=$HOME/local/ruby-1.9.1The advantage of this is that one can have many versions installed at once. (For example, many versions of Ruby.) Also, the software can be uninstalled with a simple
rm -rf ~/local/ruby-1.9.1. The disadvantage is that you have many bin/ and lib/ directories and it's a pain to maintain the $PATH. To handle this, do the following in your .zshenv (or .bashrc or whatever)
for i in $HOME/local/*; do
[ -d $i/bin ] && PATH="${i}/bin:${PATH}"
[ -d $i/include ] && CPATH="${i}/include:${CPATH}"
[ -d $i/lib ] && LD_LIBRARY_PATH="${i}/lib:${LD_LIBRARY_PATH}"
[ -d $i/lib/pkgconfig ] && PKG_CONFIG_PATH="${i}/lib/pkgconfig:${PKG_CONFIG_PATH}"
[ -d $i/share/man ] && MANPATH="${i}/share/man:${MANPATH}"
done