
When run without root privileges, it installs into a local perl library. (Generally running as root is not recommended.) When run as root it installs into the system libraries. It can be run with or without root privileges.
#Install perl install#
Install CPAN modules into your local Perl library using App::cpanminusĬPAN has evolved and the easiest way now to install CPAN modules is using the CPAN:App::cpanminus installer.

See for an overview of Perl CPAN related ebuilds. To do so, type sudo apt-get install libcgi-pm-perl from the command line or install it with your favorite package manager. One possible solution is to install libcgi-pm-perl, which currently replaces the default version by a supported one (). These versions, according to Foswiki documentation, must be avoided. On Ubuntu you might find that by default CGI v3.37, 3.43 or 3.47 are installed. You can also use GUI tools such as Synaptic to find and install such modules. apt-get libcgi-session-perl installs the CGI::Session module from CPAN. The good thing with Debian is that they carry most of the CPAN libraries on the official package repositories so once you know what they are called they are just a simple apt-get away, e.g.

(Change to lowercase, add lib prefix, replace :: with - and add -perl suffix). For example, the CGI::Session library is called libcgi-session-perl. You may need to first install epel-release EPEL is Extra Packages for Enterprise Linuxįor Debian based distributions, including Ubuntu, the naming convention is a little different.

But there are many additional repositories that carry nearly all the CPAN libraries. Not all the CPAN libraries can be found on your CD/DVD or in the official distribution package repositories. (add perl- prefix, and replace :: with -). If you need a CPAN library called CPAN:CGI::Session then the naming convention normally used is perl-CGI-Session. most CPAN libraries are available as RPM packages. If your system is one of the more popular Linux distributions then by far the easiest way to install additional CPAN modules is to use the package management system.įor distributions like RedHat, CentOS, Fedora, Mandriva, etc. Install CPAN Modules using the package management system If you think a perl module is installed, but the system claims it can't find it, then it's worth reviewing HowFoswikiFindsPerlLibraries to help understand what is going on. To check perl module Time::Local: perl -e 'use Time::Local print $Time::Local::VERSION."\n"'.To check for perl module FileHandle: perl -e 'use FileHandle print $FileHandle::VERSION."\n"'.To test if you have a specific CPAN modules installed, follow this easy method: This will report any missing dependencies.

#Install perl how to#
This guide tells you how to do that.įor building the CPAN modules from sources it is assumed that you have a fully working Perl and C development environment (including a C compiler and make tool) - but you may have much easier alternatives. It is recommended that you use your system package manager, or if necessary, App::cpanminus to install any missing dependencies. Standard Perl already has many CPAN libraries pre-installed.Īs of Foswiki 2.0, Foswiki no longer ships with any CPAN modules.
#Install perl archive#
