Installing PDL Manually
Whereas Installing PDL the quick and easy way covers installing PDL using package management tools, here I will assume that you want to install PDL from source. This page covers the how and why of doing just that.
Why install PDL Manually?
That's a good question, and I'm glad you asked. You might install PDL manually for a number of reasons, some of which probably include:
- you have an operating system or flavor of Linux that does not contain a pre-packaged version of PDL, or which contains an old version of PDL;
- you want to test the new PDL release one some of your scripts before installing it;
- you want to contribute to the development of PDL (thanks!);
- you're trying to debug problems with an install, and the manual installation gives you more diagnostics and control;
- you want your own, customized build of PDL, and the manual installation gives you more diagnostics and control.
Whatever your reasons, this page should get you through the configuration and installation phase of installing PDL manually.
When it comes to acquiring the source code for PDL, you have at least three options: you can manually download the files from Sourceforge, you can install PDL through the CPAN shell, or you can pull the sources from the GIT repository.
You can find the latest official releases on sourceforge at https://sourceforge.net/projects/pdl/. The files are distributed as a gzipped tarball. To extract them, use your archive manager software, or (if you've got a Unix-like system) at the prompt type go to the directory where you saved the downloaded archive and issue this command:
tar -xzf PDL-2.4.4.tar.gz
The basic procedure goes as follows:
- Make sure you have a fully build system, including a fortran compiler
- Install PDL's dependencies using the CPAN shell:
- Go to http://search.cpan.org/~chm/ (Chris Marshall's CPAN Author page)
- Download the latest PDL distribution tarball
- cd PDL-version_string
- edit perldl.conf
- perl Makefile.PL
- make test
- make doctest
- perl -Mblib perldl (to test the perldl shell)
- make install