Newbie Guide to CPAN
In my current project I have the pleasure (?) to work with Perl. I found out that there are hundres (thousands?) of useful modules out there. Before they can be used however, they have to be downloaded an installed… Grief!
Here’s the dummies guide to doing it: (Assuming a Cygwin installation on a Win32 box)
-
Locate the module on Cpan
-
Download the module.
-
You have a module-version.tar.gz.tar file which is useless (or so it seems)
-
mv module-version.tar.gz.tar module-version.tar.gz
. This removes the extra .tar extension…
- gzip -dc module-version.tar.gz | tar -xof -
. This extracts the module and creates a directory called “module-version”
- In that directory:
perl Makefile.PL
make
make test
make install
- Now you should have the module installed and running
Thanks to the Install FAQ