Hi, I was going through perldoc perlrun and here it has to say about PERL5LIB:
=============================================== PERL5LIB A colon-separated list of directories in which to look for Perl library files before looking in the standard library and the current directory. Any architecture-specific directories under the specified locations are automatically included if they exist. If PERL5LIB is not defined, PERL- LIB is used.
When running taint checks (either because the program was running setuid or setgid, or the -T switch was used), nei- ther variable is used. The program should instead say:
use lib "/my/directory"; =============================================== But in my case it did look into the local libs but didnt use them.... did i miss something??
Thanks, Manish
On 04/18/2005 04:49 PM, Zentara wrote:
On Mon, 18 Apr 2005 10:42:04 +0530, [EMAIL PROTECTED] (Manish Sapariya) wrote:
Hi, So can't I set PERL5LIB so that the perl will search first my local lib directory and then system lib directory.
Something like setting PATH variable to /usr/local/bin and then /usr/bin.
Yes, you can try to do it that way.
Set the environment variable in your .bashrc like you would your $PATH
PERL5LIB=/home/user/my_perl5lib:$PERL5LIB export PERL5LIB
But I'm not sure myself, whether this will always work.
It is more certain to work, the other way I mentioned, by
directly manipulating the @INC in each script. Otherwise you may end up with hard to find bugs,
where your scripts are using some old module you have
in my_perl5lib, instead of the newer ones in @INC.
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>