A note on the install_prereqs script

As you have seen above, installing each package starts by running the install_prereqs script. (Here is it's documentation.) The purpose of this script is to streamline the downloading and installation of modules from CPAN that are used by each package. That is, its purpose is to resolve all the Perl software dependencies of each package.

The install_prereqs scripts is exactly the same for each package. It determines the dependencies by reading a file from the Bundle subdirectory under each package's main directory. For horae, the file read is Bundle\HoraeBundle.pm and so on.

When run, the script uses the CPAN Perl module and a generic set of configuration parameters to search CPAN for each of the dependencies. The current version of each dependency is compared to the version (if any) installed on your computer. If a new installation or an update is needed, the new version is downloaded, built, and installed.

The CPAN Perl module provides methods for determining versioning information for each module. Because there is not a widely accepted and observed versioning standard for Perl modules, these methods will, in some cases, fail to compare correctly the CPAN version with the version on your computer. In each such case, the script makes the decision to re-install the module regardless of the version on your computer.

Some of these are a bit annoying. For example, Math::Spline is needed by three of the four packages, but does not provide any versioning information. As a result, it will be installed repeatedly. There are a few other examples of this behavior. I decided that the conservative approach is best -- module installation is usually speedy, so it seems better to install repeatedly than to run the risk of missing a dependency.


BruceRavel/EvolvingSoftware/800_InstallPrereq (last edited 2009-10-09 19:46:33 by localhost)