Michael Barto wrote:

If you have downloaded the module instead of using CPAN, look at the file "INSTALL" in the module. If should tell you what to do:

#./configuration
#make
#make check         <= VERY IMPORTANT!!
#make install

Hmm, doesn't look very typical!! Most perl modules don't have an "INSTALL" file, "./configuration" will produce an error as there's no such file in the directory (you mean "./configure" I think, but it will also give an error as it's not appropriate for a perl module), and you probably shouldn't be running the first three of those things as root...

Mo, just in case you either (a) can't get the cpan script to run (it's sometimes a little finicky to set up behind a proxy server, for example), or (b) wish to do things by hand, here's the standard sequence to go through in order to install DBI.

If you have downloaded DBI-1.52.tar.gz then move it somewhere convenient (eg, a directory called "src" in your home directory; make this directory if necessary). Then

% cd ~/src
% tar zxf DBI-1.52.tar.gz
% cd DBI-1.52
% perl Makefile.PL

[[ At this stage you might get warnings about missing prerequisite modules; in that case you will have to install them beforehand using the same procedure described here. This can cause quite a bit of cascading backwards if the module you're installing has a lot of dependencies: getting stuck in such an installation cycle will make you appreciate cpan (the script, not the repository). ]]

% make
% make test

[[ Then if the tests all pass...]]

% sudo make install

The last of these will ask for your password (I'm assuming you're an admin user). The module will automatically be installed in the appropriate place on your machine. No need to manually copy anything anywhere.

Best of luck,
Paul


Reply via email to