File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 3
3
ARG_WITH ( "curl" , "cURL support" , "no" ) ;
4
4
5
5
if ( PHP_CURL != "no" ) {
6
- if ( CHECK_LIB ( "libcurl_a.lib;libcurl.lib" , "curl" , PHP_CURL ) &&
6
+ var curl_location ;
7
+ if ( ( curl_location = CHECK_LIB ( "libcurl_a.lib;libcurl.lib" , "curl" , PHP_CURL ) ) &&
7
8
CHECK_HEADER_ADD_INCLUDE ( "curl/easy.h" , "CFLAGS_CURL" ) &&
8
9
SETUP_OPENSSL ( "curl" , PHP_CURL ) >= 2 &&
9
10
CHECK_LIB ( "winmm.lib" , "curl" , PHP_CURL ) &&
@@ -15,7 +16,10 @@ if (PHP_CURL != "no") {
15
16
) {
16
17
EXTENSION ( "curl" , "interface.c multi.c share.c curl_file.c" ) ;
17
18
AC_DEFINE ( 'HAVE_CURL' , 1 , "Define to 1 if the PHP extension 'curl' is available." ) ;
18
- ADD_FLAG ( "CFLAGS_CURL" , "/D CURL_STATICLIB /D PHP_CURL_EXPORTS=1" ) ;
19
+ ADD_FLAG ( "CFLAGS_CURL" , "/D PHP_CURL_EXPORTS=1" ) ;
20
+ if ( curl_location . match ( / l i b c u r l _ a \. l i b $ / ) ) {
21
+ ADD_FLAG ( "CFLAGS_CURL" , "/D CURL_STATICLIB" ) ;
22
+ }
19
23
PHP_INSTALL_HEADERS ( "ext/curl" , "php_curl.h" ) ;
20
24
} else {
21
25
WARNING ( "curl not enabled; libraries and headers not found" ) ;
You can’t perform that action at this time.
0 commit comments