SPUG: Installing modules w/o superuser perms

DeRykus, Charles E charles.e.derykus at boeing.com
Thu Nov 25 19:15:38 CST 2004

In addition to tweaking the Makefile just suggested, you might want 
to install the Module::Builder at the same time for future usage or
until MakeMaker gets outfitted with an INSTALLBASE option.  

It sounds like its "install_base=~" option is a real local install; whereas,
MakeMaker's PREFIX isn't. (see p5p note below).

Charles DeRykus

On Tue, Nov 23, 2004 at 09:53:41AM -0800, Justin Mason wrote:
> I took a look at Module::Builder a while back, and noted that it 
> didn't yet support the equivalent of
>     perl Makefile.PL PREFIX=$HOME
> to install into non-/usr locations.  That's a requirement for 
> SpamAssassin at least.  Has that been fixed?

Module::Build has the moral equivalent in install_base.

	perl Build.PL install_base=~

This is different from PREFIX in that its not going to try and guess how you want things installed based on your system installation.  It's just going to plop things into ~/bin, ~/lib, ~/man, etc...  This is much saner and easier to predict than PREFIX.

Unfortunately, this often means MB will put things in a slightly different location than MM does.  You can exactly control where MB puts things (as you can with MM) by passing various explicit install_* parameters so it matches exactly where MM puts its stuff.

Meanwhile, MM is going to have INSTALLBASE added to it to emulate MB. Also there are plans afoot to have a .modulebuildrc file which stores your default Build settings so you don't have to keep passing them in on the command line.

MB has the capability of generating a Makefile.PL wrapper 
(see Module::Build::Compat).  Unfortunately this does not understand PREFIX, the logic is too hairy to emulate.  Ken and I are working on getting that working.

Michael G Schwern        schwern at pobox.com  http://www.pobox.com/~schwern/
If you got the wax out of your ears you could hear the twister picking up the trailer park of your future!

-----Original Message-----
From: Thane Williams [mailto:thane at fastmail.fm] 
Sent: Wednesday, November 24, 2004 12:30 PM
To: spug-list at pm.org
Subject: Re: SPUG: Installing modules w/o superuser perms

Ok, well, I figure out part of it. I had tried exporting PERL5LIB as "/export/home/thane/perllib". When I export it as: 

I get a lot farther. This time "make test" completes successfully... but "make install is still failing:

Warning: You do not have permissions to install into /usr/local/lib/perl5/site_perl/5.6.1/sun4-solaris at /usr/local/lib/perl5/5.6.1/ExtUtils/Install.pm line 85. Cannot forceunlink /usr/local/lib/perl5/site_perl/5.6.1/Expect.pod:
Permission denied at /usr/local/lib/perl5/5.6.1/File/Find.pm line 525
make: *** [pure_site_install] Error 255 _____________________________________________________________
Seattle Perl Users Group Mailing List  
POST TO: spug-list at mail.pm.org  http://spugwiki.perlocity.org/ ACCOUNT CONFIG: http://mail.pm.org/mailman/listinfo/spug-list
MEETINGS: 3rd Tuesdays, Location: Amazon.com Pac-Med
WEB PAGE: http://seattleperl.org/

More information about the spug-list mailing list