Wiki

Clone wiki

FAST / installStat

How to install the perl module : Statistics::Distributions

Download from : http://www.cpan.org/authors/id/M/MI/MIKEK/ :

Do the following steps :

wget http://www.cpan.org/authors/id/M/MI/MIKEK/Statistics-Distributions-1.02.tar.gz
tar -xzvf Statistics-Distributions-1.02.tar.gz
cd Statistics-Distributions-1.02/
perl Makefile.PL
make
make test
make install

If you get the permission denied error, something like "Warning: You do not have permissions to install ... " or "Permission denied at ...", it means that you don't have root permission to install a module in the usual place on a shared user system. In that case you have to make a local system:

Say, you want to install the perl module at /home/user/lib directory. First create the directory for installation : mkdir /home/user/lib.

The do

perl Makefile.PL PREFIX=/home/user/lib LIB=/home/user/lib
make
make test
make install
This will install the perl module in the directory : /home/user/lib/.

Now when you run a perl program that makes use of the module, you need to tell perl where your module can be found.

export PERL5LIB=$PERL5LIB:/home/epi/pchanda/software/Perl/lib (unix bash shell)
You should add the above line to your .bashrc / .bash_profile file located in your home directory, otherwise you will need to re-do the 'export' command as above everytime you log into the system. These instructions are inspired by http://www.perlmonks.org/index.pl?node_id=128077.

Updated