LiteSpeed Support Forums

LiteSpeed Support Forums (http://www.litespeedtech.com/support/forum/index.php)
-   PHP (http://www.litespeedtech.com/support/forum/forumdisplay.php?f=19)
-   -   [solved] Error while Compile PHP with LSAPI (http://www.litespeedtech.com/support/forum/showthread.php?t=5667)

smartcard 01-30-2012 01:22 AM

[solved] Error while Compile PHP with LSAPI
 
Hello, I am getting the following error while trying to compile the PHP 5

Quote:

checking for specified location of the MySQL UNIX socket... no
checking for MySQLi support... yes
checking whether to enable embedded MySQLi support... no
mysql_config not found
configure: error: Please reinstall the mysql distribution
**ERROR** Could not configure PHP build

webizen 01-30-2012 10:16 AM

http://www.litespeedtech.com/support...i:troubleshoot

compile php with following option:
'--with-mysqli=shared,/usr/bin/mysql_config'
or
'--with-mysqli=/usr/bin/mysql_config'

make sure you have mysql rpm (contains /usr/bin/mysql_config) install.

smartcard 01-30-2012 10:25 AM

Thanks for the reply.
I am done with the PHP 5 compile, but can't connect to MySql


Code:

/home/me/lsws/fcgi-bin/lsphp5 -i|grep default_socket
is giving the following result

Quote:

mysqli.default_socket => no value => no value
default_socket_timeout => 60 => 60

webizen 01-30-2012 10:49 AM

you can define mysqli.default_socket in php.ini used by lsphp5 or define socket in my.cnf.

smartcard 01-31-2012 12:29 AM

I solved the problem by combiling PHP5 with the following

Quote:

'--with-mysqli' '--with-zlib' '--with-gd' '--enable-shmop' '--enable-track-vars' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-magic-quotes' '--enable-mbstring' '--with-iconv' '--enable-gd-native-ttf' '--with-pdo-mysql' '--enable-pdo' '--with-libdir=lib' '--with-mysql' '--with-mcrypt' '--with-jpeg-dir=/usr/lib' '--with-png-dir=/usr/lib' '--with-png' '--with-jpeg' '--with-sqlite'


All times are GMT -7. The time now is 11:08 AM.