I need to specify a directory when compiling php with --with-curl=
The curl binary is located at /usr/bin/curl
curl -V
gives me
curl 7.15.5 (x86_64-redhat-linux-gnu) libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5
locate curl
gives me
/usr/bin/curl
/usr/lib/libcurl.so.3
/usr/lib/libcurl.so.3.0.0
/usr/lib64/libcurl.so.3
/usr/lib64/libcurl.so.3.0.0
removed /usr/share/... and other irrelevant files
UPDATE
Tried --with-curl=/usr/lib64
and --with-curl=/usr/lib
although I'm pretty sure it's 64 bit.
checking for cURL support... yes
checking if we should use cURL for url streams... no
checking for cURL in default path... not found
configure: error: Please reinstall the libcurl distribution -
easy.h should be in <curl-dir>/include/curl/
SOLUTION
PHP requires curl-devel
None of these will allow you to compile PHP with cURL enabled.
In order to compile with cURL, you need libcurl header files (.h files). They are usually found in
/usr/include/curl
. They generally are bundled in a separate development package.Per example, to install libcurl in Ubuntu:
Or CentOS:
Then you can just do:
If you compile cURL manually, you can specify the path to the files without the
lib
orinclude
suffix. (e.g.:/usr/local
if cURL headers are in/usr/local/include/curl
).