views:

54

answers:

1

I have a Macports installed version of php5, that is missing the curl extension. phpinfo shows /opt/local/etc/php5/php.ini as the location for php.ini, with one of the additional .ini files listed as /opt/local/var/db/php5/curl.ini

The contents of curl.ini: extension=curl.so

If I do a locate curl.so I get /opt/local/lib/php/extensions/no-debug-non-zts-20090626/curl.so /opt/local/var/macports/software/php5-curl/5.3.2_0/opt/local/lib/php/extensions/no-debug-non-zts-20090626/curl.so

Using curl_init() in a test.php file gives me this error: Fatal error: Call to undefined function curl_init()

I'm assuming it either isn't finding the curl.so file, but I can't find extension_dir set in the php.ini and other extensions seem to work fine.

A: 

Try listing the symbols of curl.so, and search for curl_init or curl_easy_init:

nm curl.so | grep _init

There is a chance it uses the curl easy interface:

http://curl.haxx.se/libcurl/c/libcurl-easy.html

karlphillip