Le Bagage, Gautier Pelloux-Prayer

You are here:   Home > Welcome > Unix - install package without root privileges

Unix - install package without root privileges

  • Issue : how can you install package without root privileges or with choosing destination folder ?
  • Solution : for example we'll install bash-completion but the principle is always the same. This way let you install package wherever you want (if you got rights !) and not necessary in $HOME.

1. Get package source, we'll get it on the official website : bash-completion-1.3.tar.bz2 :

wget http://bash-completion.alioth.debian.org/files/bash-completion-1.3.tar.bz2

2. Unzip it (we'll destroy it at the end anyway) :

tar xvf bash-completion-1.3.tar.bz2

3. Go into the new folder then you'll need to create the destination folder then to install the package :

mkdir $HOME/bash-completionpackage
cd bash-completion-1.3
./configure --prefix=$HOME/bash-completionpackage
make
make install

4. Finally if it's an executable (not the case for bash-completion), you need to edit ~/.bashrc and add :

PATH=~PATH:$HOME/progdirbin
 

(NB : progdir/bin is your executable folder)

5. Cleaning sources :

rm -r bash-completion-1.3.tar.bz2 bash-completion-1.3/