Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^2: What Makefiles do

by clscott (Friar)
on Nov 09, 2006 at 14:43 UTC ( [id://583114]=note: print w/replies, xml ) Need Help??


in reply to Re: What Makefiles do
in thread What Makefiles do

That is what I do because my company doesn't keep Perl modules in a place that Perl knows anything about.

If you provide the PREFIX variable to the perl Makefile.PL command you can install a module anywhere you want using the standard process. e.g

perl Makefile.PL PREFIX=/my/custom/INC/dir/ make make test make install

This hasn't always worked exactly as planned but it has worked for me for many years. I never install modules into the OS perl distribution and always install modules in my home directory when I'm on a system where I can't install another perl distribution or don't have root priveleges.

Refer to the perlmodinstall man/perldoc page http://perldoc.perl.org/perlmodinstall.html

CPAN and CPANPLUS can be configured to use this PREFIX by default so that you can install modules in your special place as easily as into the distribution. Just refer to their documentation.

--
Clayton

Replies are listed 'Best First'.
Re^3: What Makefiles do
by bunnyman (Hermit) on Nov 09, 2006 at 19:20 UTC

    I am paranoid about running a makefile that I did not write and know nothing about do something to an important directory. I would rather set PREFIX=/tmp/sandbox and then go check in sandbox and copy the files to /net/production/perl/lib myself.

    The point I want to make is that Perl does not really care how the files got there, so long as @INC is set correctly and the files are in there.

Re^3: What Makefiles do
by sgt (Deacon) on Nov 09, 2006 at 22:45 UTC

    when I'm on a system where I can't install another perl distribution or don't have root privileges

    why talk about root. A user lile perlinstall is fine. I am actually paranoid about doing make install as root...especially when you don't need it.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://583114]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-04-25 17:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found