You don't necessarily need to build and install the module. If the module is pure Perl and the build process doesn't create any new code files, you may be able to use a module while it's "still in the box". Assuming that's the case, there's more than one way to do it.
EDIT: It doesn't look like Date::Calc
is pure Perl. You will probably at least have to build it before you can use the module.
Set the $PERL5LIB
environment variable to include the package distribution directory.
Invoke perl
with the -I
switch
perl -I/the/distribution/dir myscript.pl
Put the -I switch on the #! (first) line of the script
#!/usr/bin/perl -I/the/distribution/dir
Use use lib
in the script
use lib qw(/the/distribution/dir);
use The::Package;
Put the distribution directory into the @INC
variable
push @INC, "/the/distribution/dir";
require The::Package;
or
BEGIN {
push @INC, "/the/distribution/dir";
}
use The::Package;