Extracting and Compiling Perl

When you've successfully downloaded the Perl source code, extract it from its archive. There are two steps required to extract the Perl archive; decompressing it using gzip, and expanding the archive using tar. To unzip the file, use the following command:

gzip -d latest.tar.gz

Then, untar the file using this command:

tar xvf latest.tar

As the tar program runs, a list of all the files being extracted from the archive will be printed on the screen. Don't worry about the output. A directory named perl5.6.1 or something similar will be created with all the Perl files inside.

Detailed installation instructions can be found in the README and INSTALL files; I'll summarize the process in the following sections.

Running ...

Get Sams Teach Yourself Perl in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.