Re: use lib relative pathnames - redux
- From: John Bokma <john@xxxxxxxxxxxxxxx>
- Date: 9 Dec 2005 00:24:47 GMT
Tookelso@xxxxxxxxx wrote:
> Hello,
>
> I'm trying to use libraries that are relative to the perl module or
> script that's being called.
>
> The below code will not work
> use lib '../lib'
> if I execute the script from a different drive letter, or from a
> different directory in Windows.
>
> I found this thread from 8 years ago: http://tinyurl.com/drsoh
>
> Some people were going to use the following code:
>
> use lib File::Basename::dirname(__FILE__) . "../lib";
>
> Is there a more up to date solution?
Don't know about up to date, but I used this one in the past:
http://search.cpan.org/~nwclark/perl-5.8.7/lib/FindBin.pm
--
John Small Perl scripts: http://johnbokma.com/perl/
Perl programmer available: http://castleamber.com/
I ploink googlegroups.com :-)
.
- References:
- use lib relative pathnames - redux
- From: Tookelso
- use lib relative pathnames - redux
- Prev by Date: Module to interface to libmusicxml ?
- Next by Date: Need to test this Captcha on somebody's Perl
- Previous by thread: use lib relative pathnames - redux
- Next by thread: Module to interface to libmusicxml ?
- Index(es):
Relevant Pages
|
|