xref: /PHP-7.2/ext/mysqli/config.w32 (revision 902d39a3)
1// $Id$
2// vim:ft=javascript
3
4// Note: The extension name is "mysqli", you enable it with "--with-mysqli".
5// Passing value "mysqlnd" to it enables the bundled
6// client library to connect to the MySQL server, i.e. no external MySQL
7// client library is needed to perform the build.
8
9ARG_WITH("mysqli", "MySQLi support", "no");
10
11if (PHP_MYSQLI != "no") {
12	mysqli_source =
13		"mysqli.c " +
14		"mysqli_api.c " +
15		"mysqli_driver.c " +
16		"mysqli_embedded.c " +
17		"mysqli_exception.c " +
18		"mysqli_fe.c " +
19		"mysqli_nonapi.c " +
20		"mysqli_prop.c " +
21		"mysqli_result_iterator.c " +
22		"mysqli_report.c " +
23		"mysqli_warning.c";
24
25	if (PHP_MYSQLI == "yes" || PHP_MYSQLI == "mysqlnd") {
26		EXTENSION("mysqli", mysqli_source, PHP_MYSQLI_SHARED, "/DZEND_ENABLE_STATIC_TSRMLS_CACHE=1");
27		AC_DEFINE('MYSQLI_USE_MYSQLND', 1, 'Using MySQL native driver');
28		AC_DEFINE('HAVE_MYSQLILIB', 1, 'Have MySQLi library');
29		ADD_EXTENSION_DEP('mysqli', 'mysqlnd', true);
30		MESSAGE("\tmysqlnd build");
31		PHP_INSTALL_HEADERS("ext/mysqli", "php_mysqli_structs.h");
32	} else {
33		if (CHECK_LIB("libmysql.lib", "mysqli", PHP_MYSQLI) &&
34			CHECK_HEADER_ADD_INCLUDE("mysql.h", "CFLAGS_MYSQLI", PHP_MYSQLI +
35										"\\include;" + PHP_PHP_BUILD +
36										"\\include\\mysql;" + PHP_MYSQLI)) {
37			EXTENSION("mysqli", mysqli_source, PHP_MYSQLI_SHARED, "/DZEND_ENABLE_STATIC_TSRMLS_CACHE=1");
38			AC_DEFINE('HAVE_MYSQLILIB', 1, 'Have MySQLi library');
39			MESSAGE("\tlibmysql build");
40			PHP_INSTALL_HEADERS("ext/mysqli", "php_mysqli_structs.h");
41		} else {
42			WARNING("mysqli not enabled; libraries and headers not found");
43			PHP_MYSQLI = "no"
44		}
45	}
46}
47