Skip to content

Commit 6eeb7b5

Browse files
committed
curl patch
1 parent f96e372 commit 6eeb7b5

File tree

1 file changed

+6
-27
lines changed

1 file changed

+6
-27
lines changed

ext/curl/config.m4

+6-27
Original file line numberDiff line numberDiff line change
@@ -10,31 +10,19 @@ if test "$PHP_CURL" != "no"; then
1010
CURL_DIR=$PHP_CURL
1111
else
1212
AC_MSG_CHECKING(for cURL in default path)
13-
for i in /usr/local /usr; do
14-
if test -r $i/include/curl/easy.h; then
13+
for i in /usr/local /usr /system; do
14+
if test -r $i/develop/headers/curl/easy.h; then
1515
CURL_DIR=$i
1616
AC_MSG_RESULT(found in $i)
1717
break
1818
fi
1919
done
20-
if test -z "$CURL_DIR"; then
21-
AC_MSG_RESULT(not found)
22-
if which dpkg-architecture>/dev/null; then
23-
AC_MSG_CHECKING(for cURL in multiarch path)
24-
CURL_MULTIARCH_INCLUDE=/usr/include/$(dpkg-architecture -qDEB_HOST_MULTIARCH)
25-
if test -r $CURL_MULTIARCH_INCLUDE/curl/easy.h; then
26-
CURL_DIR=/usr
27-
AC_MSG_RESULT(found in $CURL_MULTIARCH_INCLUDE)
28-
else
29-
AC_MSG_RESULT(not found)
30-
fi
31-
fi
32-
fi
3320
fi
3421

3522
if test -z "$CURL_DIR"; then
36-
AC_MSG_ERROR(Could not find cURL, please reinstall the libcurl distribution -
37-
easy.h should be in <curl-dir>/include/curl/)
23+
AC_MSG_RESULT(not found)
24+
AC_MSG_ERROR(Please reinstall the libcurl distribution -
25+
easy.h should be in <curl-dir>/develop/headers/curl/)
3826
fi
3927

4028
CURL_CONFIG="curl-config"
@@ -57,11 +45,7 @@ if test "$PHP_CURL" != "no"; then
5745
AC_MSG_ERROR(cURL version 7.10.5 or later is required to compile php with cURL support)
5846
fi
5947

60-
if test -z "$CURL_MULTIARCH_INCLUDE"; then
61-
PHP_ADD_INCLUDE($CURL_DIR/include)
62-
else
63-
PHP_ADD_INCLUDE($CURL_MULTIARCH_INCLUDE)
64-
fi
48+
PHP_ADD_INCLUDE($CURL_DIR/include)
6549
PHP_EVAL_LIBLINE($CURL_LIBS, CURL_SHARED_LIBADD)
6650
PHP_ADD_LIBRARY_WITH_PATH(curl, $CURL_DIR/$PHP_LIBDIR, CURL_SHARED_LIBADD)
6751

@@ -73,13 +57,10 @@ if test "$PHP_CURL" != "no"; then
7357

7458
save_CFLAGS="$CFLAGS"
7559
CFLAGS="`$CURL_CONFIG --cflags`"
76-
save_LDFLAGS="$LDFLAGS"
77-
LDFLAGS="`$CURL_CONFIG --libs`"
7860

7961
AC_PROG_CPP
8062
AC_MSG_CHECKING([for openssl support in libcurl])
8163
AC_TRY_RUN([
82-
#include <strings.h>
8364
#include <curl/curl.h>
8465
8566
int main(int argc, char *argv[])
@@ -107,7 +88,6 @@ int main(int argc, char *argv[])
10788

10889
AC_MSG_CHECKING([for gnutls support in libcurl])
10990
AC_TRY_RUN([
110-
#include <strings.h>
11191
#include <curl/curl.h>
11292
11393
int main(int argc, char *argv[])
@@ -134,7 +114,6 @@ int main(int argc, char *argv[])
134114
])
135115

136116
CFLAGS="$save_CFLAGS"
137-
LDFLAGS="$save_LDFLAGS"
138117
else
139118
AC_MSG_RESULT([no])
140119
fi

0 commit comments

Comments
 (0)