I'm using macports supplied perl 5.16.3 installed in /opt/local/bin on my macbook 10.6
jason-danckss-macbook:eg Jason$ which perl
/opt/local/bin/perl
I was testing the demo.pl file that came with AI:Categorizer.pm from metaCPAN. I installed AI:Categorizer via CPAN supplied with macports perl:
tried to run it:
original:
./demo.pl /users/Jason/Desktop/Dropbox/capstone/capstone/notes/HTML/sock
Can't locate AI/Categorizer.pm in @INC (@INC contains: /sw/lib/perl5/5.10.0/darwin-thread-multi-
2level /sw/lib/perl5/5.10.0 /sw/lib/perl5/darwin-thread-multi-2level /sw/lib/perl5 /sw/lib/perl5
/darwin /Library/Perl/Updates/5.10.0 /System/Library/Perl/5.10.0/darwin-thread-multi-2level
/System/Library/Perl/5.10.0 /Library/Perl/5.10.0/darwin-thread-multi-2level /Library/Perl/5.10.0
/Network/Library/Perl/5.10.0/darwin-thread-multi-2level /Network/Library/Perl/5.10.0 /Network
/Library/Perl /System/Library/Perl/Extras/5.10.0/darwin-thread-multi-2level /System/Library
/Perl/Extras/5.10.0 .) at ./demo.pl line 21.
BEGIN failed--compilation aborted at ./demo.pl line 21.
slightly modified with: use lib "/opt/local/lib/perl5/5.16.3";
because that's where the modules are being written when I use CPAN (I use perl -MCPAN -e shell
IDK if that matters)
jason-danckss-macbook:eg Jason$ ./demo.pl ../HTML/sock
Can't locate AI/Categorizer.pm in @INC (@INC contains: /opt/local/lib/perl5/5.16.3/darwin-thread-
multi-2level /opt/local/lib/perl5/5.16.3 /sw/lib/perl5/5.10.0/darwin-thread-multi-2level /sw/lib
/perl5/5.10.0 /sw/lib/perl5/darwin-thread-multi-2level /sw/lib/perl5 /sw/lib/perl5/darwin
/Library/Perl/Updates/5.10.0 /System/Library/Perl/5.10.0/darwin-thread-multi-2level /System
/Library/Perl/5.10.0 /Library/Perl/5.10.0/darwin-thread-multi-2level /Library/Perl/5.10.0
/Network/Library/Perl/5.10.0/darwin-thread-multi-2level /Network/Library/Perl/5.10.0 /Network
/Library/Perl /System/Library/Perl/Extras/5.10.0/darwin-thread-multi-2level /System/Library
/Perl/Extras/5.10.0 .) at ./demo.pl line 21.
BEGIN failed--compilation aborted at ./demo.pl line 21.
check its in the right spot:
jason-danckss-macbook:eg Jason$ find /opt/local/lib/perl5 -name 'Categorizer.pm'
/opt/local/lib/perl5/site_perl/5.16.3/AI/Categorizer.pm
I even tried to use diagnostic. Neither I nor perl can find diagnostic.pm. CPAN cant find it. I'm guessing it was removed in more recent perl versions?
OK so I have both fink and macports on my computer, along with a default perl installation. the macports version perl is the first perl found in $PATH. I'm OK with it after all its its pretty recent: 5.16.3
I don't know or think reading modules from multiple locations is a bad idea. but IDK. I'd hate to think what kind of gymnastics I might need to do to fix this.
Has anyone encountered this before?