I'm trying to install PHP5 on my SuSE10 with Apache2.2 and MySQL5. when I try to make php it exits with this message:

# ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/local/mysql/ --with-mysql-sock=/usr/local/mysql/tmp/mysql.sock

......................

/usr/local/php-4.4.2/ext/mysql/php_mysql.c:1163: undefined reference to `mysql_create_db'
ext/mysql/php_mysql.lo: In function `zif_mysql_drop_db':
/usr/local/php-4.4.2/ext/mysql/php_mysql.c:1205: undefined reference to `mysql_drop_db'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1

Does anybody know what I need to do to make it work?

    4 days later

    Never mind, I got it to work...
    I did --with-mysqli instead of --with-mysql and it made it without any errors.
    I have apache, mysql and php up and running now, except now, when I call mysql functions in a php script, it complains about a missing socket or something like that.... I'm on my windows box now, otherwise I'd give a more detailed explanation.
    Anyone else have problems with a socket error in php and mysql?

      Write a Reply...