Installing perl modules in non standard directory

Source: http://modperlbook.org/html/3-9-1-Installing-Perl-Modules-into-a-Nonstandard-Directory.html

Specifying PREFIX=/home/user is the only part of the installation process that is different from usual. Note that if you don’t like how Makefile.PL chooses the rest of the directories, or if you are using an older version of it that requires an explicit declaration of all the target directories, you should do this:

$ perl Makefile.PL PREFIX=/home/user \
INSTALLPRIVLIB=/home/user/lib/perl5 \
INSTALLSCRIPT=/home/user/bin \
INSTALLSITELIB=/home/user/lib/perl5/site_perl \
INSTALLBIN=/home/user/bin \
INSTALLMAN1DIR=/home/user/lib/perl5/man \
INSTALLMAN3DIR=/home/user/lib/perl5/man3

The rest is as usual:

$ make
$ make test
$ make install

 

 

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *