Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

cgi use custom lib as last recourse

by leocharre (Priest)
on Feb 11, 2010 at 16:06 UTC ( #822677=perlquestion: print w/ replies, xml ) Need Help??
leocharre has asked for the wisdom of the Perl Monks concerning the following question:

I'm thinking of packaging a web interface to an application.

There are deps- Such as CGI::Session, for example. So something occurred to me- to potentially make it extra easy for everyday people to use- who might or might not have perl module deps system wide. But if they do- use that as a default.

I could include in the distro, a lib/depshere filesystem "branch" with the some module deps. But what if they already have the modules installed on the system?

I basically would want to look inside the ./ path as a last, not first recourse. Should I simply reverse @INC, or do something like a push @INC, $pathtoaltlib in a BEGIN block? The last seems to work.

Seems that if I don't use 'use lib..' at all- the cwd is scanned as a last place to look into.

Comment on cgi use custom lib as last recourse
Re: cgi use custom lib as last recourse
by ikegami (Pope) on Feb 11, 2010 at 16:15 UTC
    If they can install your module, they can install the dependencies too.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://822677]
Approved by hok_si_la
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2014-07-30 22:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (241 votes), past polls