Compiling PHP 5.0.2 and mysqli extension: error on 'make'

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!


I am compiling PHP 5.0.2 myself with MySQL support.

I did a ./configure --with-mysqli=/usr/local/mysql/bin/mysql_config
(see end of post for complete configure)
Note: I also have --with-mysql=/usr/local/mysql/. However, I get the
same errors when I configure without the mysql extension, just mysqli.
And as the documentation says, I use the same version of MySQL for both
extensions to avoid conflicts.

The configure script works fine, no errors. However when I do 'make', I
get errors.

I first get a series of
         In function `stmt_num_rows_read':
         undefined reference to `mysql_stmt_num_rows'
(I get about 20 different ones.)

At the end of make, I get
     collect2: ld returned 1 exit status
     make: *** [sapi/cli/php] Error 1

I am using GNU/Linux Debian Sarge. I have uninstalled the mysql-client
and mysql-server packages (4.0.x) and installed the mysql binaries
(found on into /usr/local/mysql myself (as I absolutely need
Unicode support in my databases, which requires version 4.1+).

The version of MySQL is mysql-standard-4.1.7-pc-linux-i686. It works
fine. The /usr/local/mysql/bin/mysql_config file exists.

I don't know where this could be coming from. Especially as the
configure script checks to see if everything is there and returns no errors.

(Here is my complete configure line:
../configure  --with-apxs2=/usr/bin/apxs2 --with-mysql=/usr/local/mysql/
--disable-short-tags --enable-magic-quotes --with-snmp --with-pgsql
--with-ldap --enable-sqlite-utf8 --with-gettext
--with-mysqli=/usr/local/mysql/bin/mysql_config )

I would really appreciate some help. Thank you.

Site Timeline