1PHP_ARG_ENABLE([mysqlnd], 2 [whether to enable mysqlnd], 3 [AS_HELP_STRING([--enable-mysqlnd], 4 [Enable mysqlnd explicitly, will be done implicitly when required by other 5 extensions])], 6 [no], 7 [yes]) 8 9dnl Empty variable means 'no' (for phpize builds). 10AS_VAR_IF([PHP_OPENSSL],, [PHP_OPENSSL=no]) 11 12PHP_ARG_WITH([mysqlnd-ssl], 13 [whether to enable extended SSL support in mysqlnd], 14 [AS_HELP_STRING([--with-mysqlnd-ssl], 15 [Explicitly enable extended SSL support in the mysqlnd extension when 16 building without openssl extension or when using phpize. If the openssl 17 extension is enabled at the configure step (--with-openssl), extended SSL is 18 enabled implicitly regardless of this option.])], 19 [$PHP_OPENSSL], 20 [no]) 21 22PHP_ARG_ENABLE([mysqlnd-compression-support], 23 [whether to enable compressed protocol support in mysqlnd], 24 [AS_HELP_STRING([--disable-mysqlnd-compression-support], 25 [Disable support for the MySQL compressed protocol in mysqlnd])], 26 [yes], 27 [no]) 28 29dnl If some extension uses mysqlnd it will get compiled in PHP core 30if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes"; then 31 AS_VAR_IF([PHP_MYSQLND_COMPRESSION_SUPPORT], [no],, 32 [PHP_SETUP_ZLIB([MYSQLND_SHARED_LIBADD], 33 [AC_DEFINE([MYSQLND_COMPRESSION_ENABLED], [1], 34 [Define to 1 if mysqlnd has compressed protocol support.])])]) 35 36 AC_DEFINE([MYSQLND_SSL_SUPPORTED], [1], 37 [Define to 1 if mysqlnd core SSL is enabled.]) 38 39 PHP_NEW_EXTENSION([mysqlnd], m4_normalize([ 40 mysqlnd_alloc.c 41 mysqlnd_auth.c 42 mysqlnd_block_alloc.c 43 mysqlnd_charset.c 44 mysqlnd_commands.c 45 mysqlnd_connection.c 46 mysqlnd_debug.c 47 mysqlnd_driver.c 48 mysqlnd_ext_plugin.c 49 mysqlnd_loaddata.c 50 mysqlnd_plugin.c 51 mysqlnd_protocol_frame_codec.c 52 mysqlnd_ps_codec.c 53 mysqlnd_ps.c 54 mysqlnd_read_buffer.c 55 mysqlnd_result_meta.c 56 mysqlnd_result.c 57 mysqlnd_reverse_api.c 58 mysqlnd_statistics.c 59 mysqlnd_vio.c 60 mysqlnd_wireprotocol.c 61 php_mysqlnd.c 62 ]), 63 [$ext_shared],, 64 [-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1]) 65 66 AS_VAR_IF([PHP_MYSQLND_SSL], [no],, 67 [PHP_SETUP_OPENSSL([MYSQLND_SHARED_LIBADD], [ 68 AC_DEFINE([MYSQLND_HAVE_SSL], [1], 69 [Define to 1 if mysqlnd extended SSL is enabled through a system library.]) 70 PHP_ADD_EXTENSION_DEP(mysqlnd, hash) 71 ])]) 72 73 PHP_INSTALL_HEADERS([ext/mysqlnd/]) 74 PHP_SUBST([MYSQLND_SHARED_LIBADD]) 75fi 76