Execute this command on a command line:
sudo perl -MCPAN -e shell
It will install CPAN if not already installed. Then it will take you to CPAN prompt.
On CPAN prompt, execute this command to install Perl module:
CPAN> install module name
For example:
CPAN> install Net::SMTP::TLS
CPAN is “Comprehensive Perl Archive Network” which is a repository of several useful Perl modules.