-
Notifications
You must be signed in to change notification settings - Fork 788
/
Copy pathconfigure.xml
152 lines (133 loc) · 4.93 KB
/
configure.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<section xml:id="mysqli.installation" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
&reftitle.install;
<para>
The <literal>mysqli</literal> extension was introduced with PHP version
5.0.0. The MySQL Native Driver was included in PHP version 5.3.0.
</para>
<section xml:id="mysqli.installation.linux">
<title>Installation on Linux</title>
<para>
The common Unix distributions include binary versions of PHP that can
be installed. Although these binary versions are typically built with
support for the MySQL extensions, the extension libraries
themselves may need to be installed using an additional package. Check
the package manager that comes with your chosen distribution for
availability.
</para>
<para>
For example, on Ubuntu the <literal>php5-mysql</literal> package installs
the ext/mysql, ext/mysqli, and pdo_mysql PHP extensions. On CentOS,
the <literal>php-mysql</literal> package also installs these three
PHP extensions.
</para>
<para>
Alternatively, you can compile this extension yourself. Building PHP from
source allows you to specify the MySQL extensions you want to use, as well
as your choice of client library for each extension.
</para>
<para>
The MySQL Native Driver is the recommended client library option, as it
results in improved performance and gives access to features not
available when using the MySQL Client Library. Refer to
<link linkend="mysqli.overview.mysqlnd">What is PHP's MySQL Native
Driver?</link> for a brief overview of the advantages of MySQL Native
Driver.
</para>
<para>
The <literal>/path/to/mysql_config</literal> represents the location of
the <literal>mysql_config</literal> program that comes with MySQL
Server.
</para>
<table xml:id="mysqli.installation.time.matrix">
<title>mysqli compile time support matrix</title>
<tgroup cols="5">
<thead>
<row>
<entry>PHP &Version;</entry>
<entry>&Default;</entry>
<entry>&ConfigureOptions;: <link linkend="mysqlnd.overview">mysqlnd</link></entry>
<entry>&ConfigureOptions;: <literal>libmysqlclient</literal></entry>
<entry>&Changelog;</entry>
</row>
</thead>
<tbody>
<row>
<entry>5.4.x and above</entry>
<entry>mysqlnd</entry>
<entry><option role="configure">--with-mysqli</option></entry>
<entry><option role="configure">--with-mysqli=/path/to/mysql_config</option></entry>
<entry>mysqlnd is the default</entry>
</row>
<row>
<entry>5.3.x</entry>
<entry>libmysqlclient</entry>
<entry><option role="configure">--with-mysqli=mysqlnd</option></entry>
<entry><option role="configure">--with-mysqli=/path/to/mysql_config</option></entry>
<entry>mysqlnd is supported</entry>
</row>
<row>
<entry>5.0.x, 5.1.x, 5.2.x</entry>
<entry>libmysqlclient</entry>
<entry>&NotAvailable;</entry>
<entry><option role="configure">--with-mysqli=/path/to/mysql_config</option></entry>
<entry>mysqlnd is not supported</entry>
</row>
</tbody>
</tgroup>
</table>
<para>
Note that it is possible to freely mix MySQL extensions and client
libraries. For example, it is possible to enable the MySQL extension
to use the MySQL Client Library (libmysqlclient), while configuring the
<literal>mysqli</literal> extension to use the MySQL Native Driver.
However, all permutations of extension and client library are
possible.
</para>
</section>
<section xml:id="mysqli.installation.windows">
<title>Installation on Windows Systems</title>
<para>
On Windows, <filename>php_mysqli.dll</filename> DLL must be enabled in
&php.ini;.
</para>
<para>
As with enabling any PHP extension (such as
<filename>php_mysqli.dll</filename>), the PHP directive
<link linkend="ini.extension-dir">extension_dir</link> should be set
to the directory where the PHP extensions are located. See also the
<link linkend="install.windows.manual">Manual Windows Installation
Instructions</link>. An example <literal>extension_dir</literal>
value is <filename>c:\php\ext</filename>.
</para>
<note>
<para>
If when starting the web server an error similar to the following
occurs: <literal>"Unable to load dynamic library
'./php_mysqli.dll'"</literal>, this is because
<filename>php_mysqli.dll</filename> cannot be found by the system.
</para>
</note>
</section>
</section>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->