X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=blobdiff_plain;f=php_http_api.h;h=f48d464dc761289e64f17fe7e389173ef1fbc83d;hp=bc3a2f5231f8bfc234fe971873eaa3aa897398e1;hb=f05a032e5e994a8b1ea8b5ab0291f1d1d6d42355;hpb=6cc24086f57aa1e8f4d6a2c12361635e7c24f60f diff --git a/php_http_api.h b/php_http_api.h index bc3a2f5..f48d464 100644 --- a/php_http_api.h +++ b/php_http_api.h @@ -17,7 +17,9 @@ #include "config.h" #endif +#ifndef PHP_WIN32 #include +#endif #include #include @@ -27,16 +29,12 @@ #include -#if defined(PHP_WIN32) -# if defined(PHP_HTTP_EXPORTS) -# define PHP_HTTP_API __declspec(dllexport) -# elif defined(COMPILE_DL_HTTP) -# define PHP_HTTP_API __declspec(dllimport) -# else -# define PHP_HTTP_API -# endif +#ifdef PHP_WIN32 +# define PHP_HTTP_API __declspec(dllexport) +#elif defined(__GNUC__) && __GNUC__ >= 4 +# define PHP_HTTP_API __attribute__ ((visibility("default"))) #else -# define PHP_HTTP_API +# define PHP_HTTP_API #endif /* make functions that return SUCCESS|FAILURE more obvious */ @@ -50,6 +48,10 @@ typedef int STATUS; # define PHP_HTTP_HAVE_HASH #endif +#if (defined(HAVE_JSON) || defined(PHP_HTTP_HAVE_EXT_JSON)) && (PHP_HTTP_SHARED_DEPS || !defined(COMPILE_DL_JSON)) +# define PHP_HTTP_HAVE_JSON +#endif + #ifdef PHP_WIN32 # define CURL_STATICLIB # define PHP_HTTP_HAVE_NETDB @@ -72,11 +74,13 @@ typedef int STATUS; #include "php_http_strlist.h" #include "php_http_misc.h" #include "php_http_resource_factory.h" +#include "php_http_options.h" #include "php_http.h" #include "php_http_cookie.h" -#include "php_http_curl.h" #include "php_http_encoding.h" +#include "php_http_info.h" +#include "php_http_message.h" #include "php_http_env.h" #include "php_http_env_request.h" #include "php_http_env_response.h" @@ -85,8 +89,6 @@ typedef int STATUS; #include "php_http_filter.h" #include "php_http_header_parser.h" #include "php_http_headers.h" -#include "php_http_info.h" -#include "php_http_message.h" #include "php_http_message_body.h" #include "php_http_message_parser.h" #include "php_http_negotiate.h" @@ -97,13 +99,15 @@ typedef int STATUS; #include "php_http_querystring.h" #include "php_http_client_interface.h" #include "php_http_client.h" +#include "php_http_curl.h" #include "php_http_client_request.h" #include "php_http_client_response.h" -#include "php_http_client_curl.h" +#include "php_http_curl_client.h" #include "php_http_client_pool.h" -#include "php_http_client_pool_curl.h" +#include "php_http_curl_client_pool.h" #include "php_http_client_datashare.h" -#include "php_http_client_datashare_curl.h" +#include "php_http_curl_client_datashare.h" +#include "php_http_client_factory.h" #include "php_http_url.h" #include "php_http_version.h"