- no need for additional configure argument; just check and enable
[m6w6/ext-http] / config.w32
1 // config.w32 for pecl/http
2 // $Id$
3
4 ARG_ENABLE("http", "whether to enable extended HTTP support", "no");
5
6 if (PHP_HTTP != "no") {
7
8 if (CHECK_HEADER_ADD_INCLUDE('mhash.h', 'CFLAGS_HTTP') &&
9 CHECK_LIB('libmhash.lib', 'http', PHP_HTTP)) {
10 AC_DEFINE('HTTP_HAVE_MHASH', 1 , "Have mhash library");
11 } else {
12 WARNING("mhash etag generator not enabled; libraries and headers not found");
13 }
14
15 EXTENSION("http",
16 "missing.c http.c http_functions.c http_exception_object.c "+
17 "http_util_object.c http_message_object.c http_requestpool_object.c "+
18 "http_request_object.c http_response_object.c "+
19 "http_api.c http_cache_api.c http_request_pool_api.c "+
20 "http_request_api.c http_date_api.c http_headers_api.c "+
21 "http_message_api.c http_send_api.c http_url_api.c "+
22 "http_info_api.c",
23 null,
24 "/I\"" + configure_module_dirname + "/phpstr\"");
25 ADD_SOURCES(configure_module_dirname + "/phpstr", "phpstr.c", "http");
26 AC_DEFINE("HAVE_HTTP", 1, "Have extended HTTP support");
27 if (CHECK_LIB("libcurl.lib", "http", PHP_HTTP) &&
28 CHECK_HEADER_ADD_INCLUDE("curl/easy.h", "CFLAGS_HTTP") &&
29 CHECK_LIB("ssleay32.lib", "http", PHP_HTTP) &&
30 CHECK_LIB("libeay32.lib", "http", PHP_HTTP) &&
31 CHECK_LIB("zlib.lib", "http", PHP_HTTP) &&
32 CHECK_LIB("winmm.lib", "http", PHP_HTTP)) {
33 AC_DEFINE("HTTP_HAVE_CURL", 1, "Have CURL library");
34 } else {
35 WARNING("curl convenience functions not enabled; libraries and headers not found");
36 }
37 }