tomgracey has asked for the wisdom of the Perl Monks concerning the following question:

I have a feeling this might be a stupid question so sorry in advance... i am still pretty new to perl! I installed perl and necessary modules on one computer a while ago, but don't remember encountering the following problem. I am using the cpan command in a dos shell (Win XP) and typing "install DBI". I get the following:
CPAN.pm: Going to build T/TI/TIMB/DBI-1.49.tar.gz *** You are using a perl configured with threading enabled. *** You should be aware that using multiple threads is *** not recommended for production environments. *** Note: The optional PlRPC-modules (RPC::PlServer etc) are not installed. If you want to use the DBD::Proxy driver and DBI::ProxyServer modules, then you'll need to install the RPC::PlServer, RPC::PlCli +ent, Storable and Net::Daemon modules. The CPAN Bundle::DBI may help yo +u. You can install them any time after installing the DBI. You do *not* need these modules for typical DBI usage. Optional modules are available from any CPAN mirror, in particular http://search.cpan.org/ http://www.perl.com/CPAN/modules/by-module http://www.perl.org/CPAN/modules/by-module ftp://ftp.funet.fi/pub/languages/perl/CPAN/modules/by-module *** You're using Microsoft Visual C++ compiler or similar but the LIB and INCLUDE environment variables are not both set. You need to run the VCVARS32.BAT batch file that was supplied with the compiler before you can use it. A copy of vcvars32.bat can typically be found in the following directories under your Visual Studio install directory: Visual C++ 6.0: vc98\bin Visual Studio .NET: vc7\bin Find it, run it, then retry this. If you think this error is not correct then just set the LIB and INCLUDE environment variables to some value to disable the check. # Looks like your test died before it could output anything. Running make test Make had some problems, maybe interrupted? Won't test Running make install Make had some problems, maybe interrupted? Won't install
As far as I'm aware I'm not using MS Visual C++, but I am also confused with what to do with LIB and INCLUDE. Can anyone shed any light on this?

Considered (rinceWind): Retitle: omit "daft"
Unconsidered (holli): Enough Keep votes (Keep: 8, Edit: 7, Reap: 0)

Replies are listed 'Best First'.
Re: daft question about installing DBI
by Corion (Patriarch) on Dec 06, 2005 at 07:48 UTC

    If you are not using MS Visual C++ ("MSVC"), then you won't be able to install DBI via the CPAN module, because the DBI has a part that needs to be compiled by a C compiler. I suggest you install the DBI via PPM or whatever module installation method your package supplies.

    If you want to install MSVC, please take care of installing exactly the version that was used to compile your Perl executable or recompile Perl with your installed version of MSVC. There are some nodes on using the free Microsoft compiler tools here:

      Yes, thanks for that, I sorted it out. I don't know why, but I was convinced I did it through cpan last time. Anyway, thanks again for your help.