diff options
author | Wez Furlong <wez@php.net> | 2003-12-05 03:14:54 +0000 |
---|---|---|
committer | Wez Furlong <wez@php.net> | 2003-12-05 03:14:54 +0000 |
commit | 1982ae6246f77cf262366384f668f7e7fbe1280d (patch) | |
tree | 9ff1f9a377c1be70308786bafef37ce195079016 /ext | |
parent | 24e54d43e6813cf109766c3a1c867e002162625e (diff) | |
download | php-git-1982ae6246f77cf262366384f668f7e7fbe1280d.tar.gz |
fix zts build
Diffstat (limited to 'ext')
-rw-r--r-- | ext/iconv/config.w32 | 17 | ||||
-rw-r--r-- | ext/iconv/iconv.c | 12 |
2 files changed, 15 insertions, 14 deletions
diff --git a/ext/iconv/config.w32 b/ext/iconv/config.w32 index 067707558a..c7e15e469a 100644 --- a/ext/iconv/config.w32 +++ b/ext/iconv/config.w32 @@ -3,13 +3,14 @@ ARG_WITH("iconv", "iconv support", "no"); -if (PHP_ICONV == "yes") { - EXTENSION("iconv", "iconv.c"); - AC_DEFINE("HAVE_ICONV", 1, "Define if iconv extension is enabled"); - AC_DEFINE("HAVE_LIBICONV", 1, "Define if libiconv is available"); - AC_DEFINE("PHP_ICONV_IMPL", "\"libiconv\"", "Which iconv implementation to use"); - AC_DEFINE("ICONV_SUPPORTS_ERRNO", 1, "Whether iconv supports errno or not"); - CHECK_LIB("iconv.lib", "iconv"); - CHECK_HEADER_ADD_INCLUDE("iconv.h", "CFLAGS"); +if (PHP_ICONV != "no") { + if (CHECK_LIB("iconv.lib", "iconv", PHP_ICONV) && CHECK_HEADER_ADD_INCLUDE("iconv.h", "CFLAGS_ICONV", PHP_ICONV)) { + EXTENSION("iconv", "iconv.c"); + + AC_DEFINE("HAVE_ICONV", 1, "Define if iconv extension is enabled"); + AC_DEFINE("HAVE_LIBICONV", 1, "Define if libiconv is available"); + AC_DEFINE("PHP_ICONV_IMPL", "\"libiconv\"", "Which iconv implementation to use"); + AC_DEFINE("ICONV_SUPPORTS_ERRNO", 1, "Whether iconv supports errno or not"); + } } diff --git a/ext/iconv/iconv.c b/ext/iconv/iconv.c index 9cc55bbe60..8be5596e9a 100644 --- a/ext/iconv/iconv.c +++ b/ext/iconv/iconv.c @@ -148,8 +148,8 @@ static php_iconv_err_t _php_iconv_mime_encode(smart_str *pretval, const char *fn static php_iconv_err_t _php_iconv_mime_decode(smart_str *pretval, const char *str, size_t str_nbytes, const char *enc, const char **next_pos, int mode); -static php_iconv_err_t php_iconv_stream_filter_register_factory(); -static php_iconv_err_t php_iconv_stream_filter_unregister_factory(); +static php_iconv_err_t php_iconv_stream_filter_register_factory(TSRMLS_D); +static php_iconv_err_t php_iconv_stream_filter_unregister_factory(TSRMLS_D); /* }}} */ /* {{{ static globals */ @@ -207,7 +207,7 @@ PHP_MINIT_FUNCTION(miconv) REGISTER_LONG_CONSTANT("ICONV_MIME_DECODE_STRICT", PHP_ICONV_MIME_DECODE_STRICT, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("ICONV_MIME_DECODE_CONTINUE_ON_ERROR", PHP_ICONV_MIME_DECODE_CONTINUE_ON_ERROR, CONST_CS | CONST_PERSISTENT); - if (php_iconv_stream_filter_register_factory() != PHP_ICONV_ERR_SUCCESS) { + if (php_iconv_stream_filter_register_factory(TSRMLS_C) != PHP_ICONV_ERR_SUCCESS) { return FAILURE; } @@ -218,7 +218,7 @@ PHP_MINIT_FUNCTION(miconv) /* {{{ PHP_MSHUTDOWN_FUNCTION */ PHP_MSHUTDOWN_FUNCTION(miconv) { - php_iconv_stream_filter_unregister_factory(); + php_iconv_stream_filter_unregister_factory(TSRMLS_C); UNREGISTER_INI_ENTRIES(); return SUCCESS; } @@ -2523,7 +2523,7 @@ static php_stream_filter *php_iconv_stream_filter_factory_create(const char *nam /* }}} */ /* {{{ php_iconv_stream_register_factory */ -static php_iconv_err_t php_iconv_stream_filter_register_factory() +static php_iconv_err_t php_iconv_stream_filter_register_factory(TSRMLS_D) { static php_stream_filter_factory filter_factory = { php_iconv_stream_filter_factory_create @@ -2539,7 +2539,7 @@ static php_iconv_err_t php_iconv_stream_filter_register_factory() /* }}} */ /* {{{ php_iconv_stream_unregister_factory */ -static php_iconv_err_t php_iconv_stream_filter_unregister_factory() +static php_iconv_err_t php_iconv_stream_filter_unregister_factory(TSRMLS_D) { if (FAILURE == php_stream_filter_unregister_factory( php_iconv_stream_filter_ops.label TSRMLS_CC)) { |