in reply to perlbrew and CPAN

G'day 1nickt,

[Disclaimer: all of the following is based on (educated) guesses.]

Firstly, /Library/Perl/5.12 indicates your system Perl (i.e. /usr/bin/perl). If you type '/usr/bin/perl -V', that should confirm v5.12; plus you'll see a number of paths (mostly under @INC) starting in the /Library, /System or /Network directories and containing '.../5.12/...' somewhere in each path.

Paths to your perlbrew versions of perl, cpan, etc. will be in a directory like /Users/nick/perl5/perlbrew/perls/perl-5.6.0/bin/.

However, I suspect the cpan utility wasn't part of the core distribution for v5.6. I seem to recall when I last used v5.6 (over a decade ago), I used CPAN interactively like this:

perl -MCPAN -e shell

So, check your $PATH, which probably looks something like:

...:/Users/nick/perl5/perlbrew/perls/perl-5.6.0/bin:...:/usr/bin:...

If my guesses have been good ones up to now, the following two commands will produce the output shown:

$ which perl /Users/nick/perl5/perlbrew/perls/perl-5.6.0/bin/perl $ which cpan /usr/bin/cpan

So, Perl v5.6.0 isn't too old, it just didn't include the cpan utility by default — you'll need to install this yourself. Also, from the little you've shown in your post, I don't see any glaring problems with your perlbrew configuration.

— Ken

Replies are listed 'Best First'.
Re^2: perlbrew and CPAN
by 1nickt (Canon) on Jul 12, 2015 at 17:42 UTC

    Thanks Ken. You nailed it. I had been using 5.16 under perlbrew for so long that I forgot about my system perl being 5.12. And sure enough perl -MCPAN -e shell worked nicely, and was a charming trip down memory lane.

    Thanks a million mate.

    Remember: Ne dederis in spiritu molere illegitimi!