ENCRYPTED CONNECTIONS via SSLĬonnecting to your servers over an encrypted connection (SSL) is only possible if you enabled this setting at build time. If this seems to be causing problem you may also try to link without gzip libraries. Once you know the name (libz.a or libgz.a is best), just add it to the list of linker flags. Typically, this is the case if you've installed the mysql library from your systems' package manager. If your MySQL distribution contains mysql_config the easiest method is to ensure this binary is on your path. This may be achieved using command line switches (see "Configuration") or automatically using the mysql_config binary which comes with most MySQL distributions. The DBD::mysql Makefile.PL needs to know where to find your MySQL installation. All of these installation types have their own section: "CPAN installation", "Manual installation" and "Configuration".
Otherwise you will need to do a manual installation. If you are lucky, the Perl module CPAN will do all for you, thanks to the excellent work of Andreas König. Please let me know if you find the files in your favorite Linux or FreeBSD distribution so that I can extend the above list.
I just cannot give you names, as I am not using these systems. In the case of other Linux or FreeBSD distributions it is very likely that all you need comes with your distribution. Zypper install perl-DBD-mysql Other systems All you need to do is typing in a cmd.exe window:
ActiveState PerlĪctivePerl offers a PPM archive of DBD::mysql. Strawberry Perl comes bundled with DBD::mysql and the needed client libraries. BINARY INSTALLATIONīinary installation is possible in the most cases, depending on your system. Thus it may be required that you have install an RPM package like libz-devel, libgz-devel or something similar. Late versions of MySQL come with support for compression. But believe me, experience shows that a lot of problems are fixed this way. In the worst case, this might mean to compile Perl and MySQL yourself. However, if you need a C compiler, make sure, that it is the same C compiler that was used for compiling Perl and MySQL! Otherwise you will almost definitely encounter problems because of differences in the underlying C runtime libraries. In most cases there are binary distributions of DBD::mysql available. C compilerĪ C compiler is only required if you install from source. It is available from the same source where you got the DBD::mysql distribution from. DBIĭBD::mysql is a DBI driver, hence you need DBI. This may require choosing a "Custom installation" and selecting the appropriate option when running the MySQL setup program.
If you are using Windows and need to compile from sources (which is only the case if you are not using ActivePerl or Strawberry Perl), then you must ensure that the header and library files are installed. You may also create client files by compiling from the MySQL source distribution and using These are sufficient, if the MySQL server is located on a foreign machine. For example, Fedora Linux distribution comes with RPM files (using YUM) mysql and mysql-server (use "yum search" to find exact package names).
You need not install the actual MySQL database server, the client files and the development files are sufficient. For Windows, use ActivePerl or Strawberry Perl.
For example, all Linux and FreeBSD distributions come with Perl. Preferably a version of Perl, that comes preconfigured with your system.
If that doesn't help, you should check the section on "SUPPORT". "SOURCE INSTALLATION".įinally, if you encounter any problems, do not forget to read the section on known problems "KNOWN PROBLEMS". Installation from binaries and sources are both described in separate sections. If so, you will definitely need a C compiler. Otherwise you need to install from the sources. For details see the separate section "PREREQUISITES".ĭepending on your version of Perl, it might be possible to use a binary distribution of DBD::mysql. Before reading on, make sure that you have the prerequisites available: Perl, MySQL and DBI.
This document describes the installation and configuration of DBD::mysql, the Perl DBI driver for the MySQL database.