Bug #28480 | error when compiling php 5.2.2 with --with-mysql | ||
---|---|---|---|
Submitted: | 16 May 2007 20:03 | Modified: | 18 May 2007 16:27 |
Reporter: | Juan Montesinos | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Compiling | Severity: | S3 (Non-critical) |
Version: | mysql-5.0.26-12 | OS: | Linux (OpenSUSE 10.2 AMD64) |
Assigned to: | Sveta Smirnova | CPU Architecture: | Any |
Tags: | MySQL, php |
[16 May 2007 20:03]
Juan Montesinos
[16 May 2007 22:03]
Sveta Smirnova
Thank you for the report. But version 5.0.26 is quite old. Please try with current MySQL 5.0.41 and if you can repeat described behaviour send us result of the command /usr/bin/mysql_config
[17 May 2007 1:35]
Juan Montesinos
Hello, I just installed the version 5.0.41 and the results of the command mysql_config are the following: ////////////////////////////////// virtual1:/usr/bin # /usr/local/mysql/bin/mysql_config Usage: /usr/local/mysql/bin/mysql_config [OPTIONS] Options: --cflags [-I/usr/local/mysql/include/mysql] --include [-I/usr/local/mysql/include/mysql] --libs [-L/usr/local/mysql//lib/mysql -lmysqlclient -lz -lcrypt -lnsl -lm] --libs_r [-L/usr/local/mysql//lib/mysql -lmysqlclient_r -lz -lpthread -lcrypt -lnsl -lm -lpthread] --socket [/usr/local/mysql/tmp/mysql.sock] --port [3306] --version [5.0.41] --libmysqld-libs [-L/usr/local/mysql//lib/mysql -lmysqld -lz -lpthread -lcrypt -lnsl -lm -lpthread -lrt] /////////////////////////////// I tried to compile again php but the problem persist, could you please help me? the configure script is: Please be aware that I installed mysql on the path /usr/local/mysql Waiting your comments, thank you
[17 May 2007 1:38]
Juan Montesinos
Sorry, I forgot the configure script: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql --with-pgsql --with-pear --with-openssl --with-zlib --with-bz2 --with-gd --with-ttf --with-png-dir --with-jpeg-dir --with-gettext --with-ldap --with-imap-ssl --with-msql --with-unixODBC=/usr/ --with-libxml-dir --enable-zip The results were: ... ... checking for MySQL support... yes checking for specified location of the MySQL UNIX socket... no checking for MySQL UNIX socket location... no configure: error: Cannot find MySQL header files under yes. Note that the MySQL client library is not bundled anymore! ... ... If you need more information, don't hesitate to request it.
[17 May 2007 7:01]
Sveta Smirnova
Thank you for the feedback. But you didn't indicate path to MySQL installation directory in the configure string. Please indicate paths correctly and report if you meet error. Note you should use --with-mysql=/path/to/mysql/installation/dir, but --with-mysqli=/path/to/mysql_config In your initial post like bug looks only error with --with-mysqli=/usr/bin/mysql_config configure option.
[18 May 2007 0:18]
Juan Montesinos
Hello Sveta, Sorry for the delay, here are the results using the 1st parameter: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/local/mysql/ --with-pgsql --with-pear --with-openssl --with-bz2 --with-gd --with-ttf --with-png-dir --with-jpeg-dir --with-gettext --with-ldap --with-imap-ssl --with-msql --with-unixODBC=/usr/ --with-libxml-dir --enable-zip //////////////////////// ... ... checking for MySQL support... yes checking for specified location of the MySQL UNIX socket... no checking for MySQL UNIX socket location... no checking for mysql_close in -lmysqlclient... no checking for mysql_error in -lmysqlclient... no configure: error: mysql configure failed. Please check config.log for more information. /////////////////// Also I used the 2nd parameter in the configure script: ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysqli=/usr/local/mysql/bin/mysql_config --with-pgsql --with-pear --with-openssl --with-bz2 --with-gd --with-ttf --with-png-dir --with-jpeg-dir --with-gettext --with-ldap --with-imap-ssl --with-msql --with-unixODBC=/usr/ --with-libxml-dir --enable-zip And the results were: ///////////////////////// checking for MySQL support... no checking for specified location of the MySQL UNIX socket... no checking for MySQLi support... yes checking whether to enable embedded MySQLi support... no checking for mysql_set_server_option in -lmysqlclient... no configure: error: wrong mysql library version or lib not found. Check config.log for more information. //////////////////////// Thank you for your advice
[18 May 2007 12:58]
Sergei Golubchik
Did you check the config.log for more information, as the error message says ? Can you attach it to the bugreport ? The only snippet of the config.log that you show (in the original submission) contains: cannot find -lmsql because you configured with --with-msql, and you apparently don't have it. Later you compile without mSQL, so there must be a different error now, but without a config.log it's impossible to see what it is.
[18 May 2007 16:27]
Juan Montesinos
Hello Team, I deleted the parameter "--with-msql" from the script and PHP compiled without errors now. I don't know why happened this issue, thank you very much for your help. Have a great day and regards from Mexico City, you can close this ticket.
[10 Nov 2007 16:12]
Vikram J. Gurjar
The simplest solution to this is : Look for a file usually called libmysqlclient.so.15.0.0 or something like that Link this to the /usr/lib and /usr/include (Redhat) or /usr/local/lib/ and /usr/local/include to a file called libmysqlclient.so.15 ln -s /usr/lib/mysql/libmysqlclient.so.15.0.0 /usr/lib/libmysqlclient.so.15 ln -s /usr/lib/mysql/libmysqlclient.so.15.0.0 /usr/include/libmysqlclient.so.15 or ln -s /usr/lib/mysql/libmysqlclient.so.15.0.0 /usr/local/lib/libmysqlclient.so.15 ln -s /usr/lib/mysql/libmysqlclient.so.15.0.0 /usr/local/include/libmysqlclient.so.15 It solved my problems.