How to build perl DBD::mysql with Cygwin on Windows XP ------------------------------------------------------ + install Cygwin -> Devel - gcc-g++ (C++ Compiler). Otherwise, you will get configuration error: checking how to run the C++ preprocessor... /lib/cpp configure: error: C++ preprocessor "/lib/cpp" fails sanity check See `config.log' for more details. + download MySQL linux source codes file: terrence@southbank /usr/local/src/mysql/5.0.22 $ ./configure --prefix=/usr/local/mysql $ make $ make install $ cp /usr/local/mysql/bin/mysql_config . $ perl -MCPAN -e shell cpan> install DBD::mysql (version 3.006) OR: $ perl Makefile.PL --testhost=127.0.0.1 --testuser=root --testpassword=getaway Note: you should use "127.0.0.1" rather than "localhost" on Windows, otherwise you will get error: Can't connect to local MySQL server through socket '/tmp/mysql.sock' Reference ========== + How to install and configure DBD::mysql - http://search.cpan.org/dist/DBD-mysql/lib/DBD/mysql/INSTALL.pod |