CPAN-shell install

From BRF-Software
Revision as of 10:06, 9 November 2005 by imported>MichaelDondrup
Jump to navigation Jump to search

Short intro on howto use the CPAN shell for installing perl modules

Note: If there is a package for the perl-module you wish to install in the distribution of your operating system, we recommend to use the package management system instead of CPAN shell.

Prerequisites

  • Perl is installed
  • The CPAN module is installed. We recommend to use the package management system of you operating system distribution to install it. (or download from: http://search.cpan.org/~andk/CPAN/).

Starting the cpan shell

You need to become a privileged user to install perl-modules (On small/semi-professional/Linux installations this is often root).

type

root# perl -MCPAN -e shell

Configuring cpan shell

When started for the first time, cpan-shell will ask you a few questions for interactive configuration. Take special care about selecting CPAN mirror sites close to you and about your proxy settings.

Installing modules

To install the module My::Module from within the cpan-shell type


cpan> install My::Module


cpan-shell will download the module source code, make and install it automatically.

For more information about the interactive install or trouble-shooting consult the documentation of the CPAN module.