Wednesday, July 14, 2010

How to install perl modules (using CPAN)

Today I've updated SpamAssassin. And it required some perl-modules.
REQUIRED module missing: HTML::Parser
optional module missing: Mail::SPF
optional module missing: IP::Country
optional module missing: Razor2
optional module missing: Net::Ident
optional module missing: IO::Socket::INET6
optional module missing: IO::Socket::SSL
optional module missing: Mail::DKIM
optional module missing: DBI
optional module missing: LWP::UserAgent
I've found quick way to install them using CPAN:
http://www.livejournal.com/doc/server/lj.install.perl_setup.modules.html

...

# perl -MCPAN -e shell

Once the Perl interpreter has loaded (and been configured), you can install modules with: install MODULENAME.

The first thing you should do is upgrade your CPAN:

cpan> install Bundle::CPAN

Once it is completed, type:

cpan> reload cpan

Now, enter the following command to retrieve all of the required modules:

cpan> install HTML::Parser

No comments: