18.1. Cameron Prince's local Perl installation how-to
- Login as user. In this example, we'll call the user bob. Bob's home directory is /home/bob.
- Get the perl tarball and extract it in /home/bob. (tar -xzvf perl-5.6.0.tar.gz)
- Create a directory for the local perl. (mkdir /home/bob/local-perl)
- Compile perl.
- cd perl-5.6.0
- sh Configure
- Choose all the defaults until you get to: "Directories to use for library searches?" Here you want to enter the new local perl path, as well as the defaults. So you should enter something like: /home/bob/local-perl/lib /usr/local/lib /lib /usr/lib
- Continue choosing defaults till you get to: "Any additional ld flags (NOT including libraries)?" This should be: -L/home/bob/local-perl/lib
- Continue choosing defaults till you get to: "Installation prefix to use? (~name ok)" This should be: /home/bob/local-perl
- Choose all defaults till you get to: "Directory /home/bob/local-perl/bin doesn't exist. Use that name anyway?" Enter y.
- Continue choosing defaults till you get to: "Do you want to install perl as /usr/bin/perl?" Enter n.
- Continue choosing defaults till you get to: "Directory /home/bob/local-perl/bin doesn't exist. Use that name anyway?" Enter y.
- Directory /home/bob/local-perl/bin doesn't exist. Use that name anyway? Enter y.
- Continue taking defaults till you return to a prompt.
- make
- make test
- make install
- /home/bob/local-perl/bin/perl -v
You should see: This is perl, v5.6.0 - edit /home/bob/.bash_rc
Change: PATH=$PATH:$HOME/bin
To: PATH=/home/bob/local-perl/bin:$PATH:$HOME/bin - Logout and log back in.
- which perl
You should see: ~/local-perl/bin/perl or /home/bob/local-perl/bin/perl - perl -MCPAN -e 'install Bundle::Interchange'
Keep running this until you see:
MD5 is up to date. MIME::Base64 is up to date. URI is up to date. Net::FTP is up to date. MIME::Base64 is up to date. Digest::MD5 is up to date. HTML::Tagset is up to date. HTML::Parser is up to date. HTML::HeadParser is up to date. LWP is up to date. Term::ReadKey is up to date. Term::ReadLine::Perl is up to date. Business::UPS is up to date. SQL::Statement is up to date. Storable is up to date. DBI is up to date. Safe::Hole is up to date.
You may need to get the modules via ftp and install them by hand. For instance, during the test used to create this document, I had to get URI and LWP and install by hand before everything reported that it was up to date. To do this, follow these steps:
- ftp ftp.cpan.org
- cd /CPAN/modules/by-module/URI
- bin
- get URI-1.10.tar.gz
- quit
- tar -xzvf URI-1.10.tar.gz
- cd URI-1.10
- perl Makefile.pl
- make
- make test
- make install
Use the same basic steps for any module not properly installed by using perl -MCPAN -e 'install Bundle::Interchange'
Now, install Interchange as normal.