Cannot load config file: couldn't open /Users/me/perl/perl_lib:/usr/local/lib/perl5/site_perl/

That's not a problem with the setting of $PERL5LIB, that's a problem with how your perl script is using it. Since you haven't shown your script I can't help you further with that.

BTW, there is no effect in exporting the same variable twice in sh/bash.

Update: just for completeness, here's a demo showing multiple entries in $PERL5LIB.

use strict; use warnings; use Path::Tiny; use Test::More tests => 3; chdir '/'; # In case you have . in @INC my $mod = path ('/tmp')->child ('ZZZZZ.pm'); $mod->spew ('package ZZZZZ;1;'); ok ! system ("PERL5LIB=/tmp:/foo perl -e 'use ZZZZZ;'"), 'First in pat +h'; ok ! system ("PERL5LIB=/foo:/tmp perl -e 'use ZZZZZ;'"), 'Second in pa +th'; ok system ("PERL5LIB=/foo:/bar perl -e 'use ZZZZZ;'"), 'Not in path' +; $mod->remove;

In reply to Re: How do you export more than one path to PERL5LIB by hippo
in thread How do you export more than one path to PERL5LIB by nysus

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.