Since it seems with your configure, ./configure --with-apxs2=/app/apache2/bin/apxs --without-pear -- with-config-file-path=/app/ini --with-mysql=/usr/local/mysql
that you're not building only for mysql extension and not for PDO/mysql, you will see in your config.log, dyld: Library not loaded: /usr/local/mysql/lib/mysql/libmysqlclient.15.dylib Referenced from: /Users/jpons/app/src/php-5.2.3/./conftest Reason: image not found Add before your configure step, setenv LDFLAGS "-bind_at_load -L/usr/local/mysql/lib/mysql -lmysqlclient" setenv CPPFLAGS "-I/usr/local/mysql/include/mysql" And try it again.