Trying to install CPAN
I am trying to use CPAN, but I am running into an issue. First I did sudo apt-get install perl. It says it's there. I typed cpan install automatically yes sudo which indicated as done, and I can get into cpan. I downloaded the .pl I wanted to use on CPAN, pointed to the directory, and tried perl file.pl. I am presented with this message:
Can't locate CAM/ODF.pm in @INC (@INC containes /etc/per/ /usr/local/lib/perl/5.14.2 /usr/local/share/perl/5.14.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.14/ .usr/share/perl/5.14 /usr/local/lib/site_perl .) at file.pl in line 7I downloaded CAM-PDF-1.59.tar.gz, double clicked, and tried placing the contents in /usr/local/lib/pkgconfig, but I am getting you don't have the right permissions.
How should I install CPAN on Ubuntu 12.10 (Quantal Quetzal) to use in the terminal? Where am I going wrong?
1 Answer
OK, you're mixing up quite a few things here.
cpanis an installer for Perl modules from the CPAN, and it is installed by default- You don't download CPAN packages manually, but do `cpan CAM::PDF' to install from CPAN.
/usr/local/lib/pkgconfigis a very strange place to put these things, better delete that again.
But all of that is not needed, as Ubuntu ships CAM::PDF:
sudo apt-get install libcam-pdf-perlGenerally, if a Perl library is named Foo::Bar on CPAN, the Debian/Ubuntu package will be named libfoo-bar-perl. Use these packages before trying to install them with cpan from CPAN.