[Purdue-pm] Module Question

Joe Kline gizmo at purdue.edu
Wed Jul 20 11:01:48 PDT 2011

Hash: SHA1

On 07/20/2011 01:54 PM, Doug Yatcilla wrote:
> On Wed Jul 20 12:02:45 2011, Dave Jacoby <jacoby at purdue.edu> wrote:
>> I have modules that run on our servers, separated by purpose. So,  
>> Dave::First calls Dave::Second in order to get, for example, the SQL  
>> interfaces.
>> And this also gets used on RCAC clusters, and I certainly don't want to  
>> have too much parallel development. Which is where 'use lib' starts to 
>> hurt.
>> On our servers, it's
>> 	use lib '/home/jacoby/lib' ;
>> 	use Dave::First ':all' ;
>> On RCAC servers, it's something way different. I can't do anything with  
>> Cwd, because that's not going to be ready until after the load library  
>> stuff happens, which is where I need it. Any suggestions?
> If there are only two systems and you keep your perl libraries in
> different directories on each system, you could put two "use lib"
> lines in your code listing both directories.
> Or, you could set the PERL5LIB shell environment variable to be the
> directory with your perl libraries.  If you use this, you won't need
> the "use lib" line in your code.  You login scripts could
> automatically set the PERL5LIB env var to the appropriate directory
> for the server or you could set it to all possible directories so the
> same PERL5LIB will work on any server you use.

It would probably be preferable to do something in a BEGIN block with
@INC rather than muck with a env var.

I would give local::lib a try first.

Version: GnuPG v2.0.14 (GNU/Linux)
Comment: Using GnuPG with Red Hat - http://enigmail.mozdev.org/


More information about the Purdue-pm mailing list