php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #40540 MySQL Undefined references
Submitted: 2007-02-19 10:06 UTC Modified: 2007-02-20 11:02 UTC
From: mikko dot kayhko at gmail dot com Assigned:
Status: Not a bug Package: Compile Failure
PHP Version: 5.2.1 OS: Fedora Core 3
Private report: No CVE-ID: None
 [2007-02-19 10:06 UTC] mikko dot kayhko at gmail dot com
Description:
------------
PHP 5.2.1.

./configure parameters: --with-apxs2=/usr/local/apache/bin/apxs --with-mysql --with-config-file-path=/usr/local/apache/php --with-ldap?

While performing "make", the following error message appears and stops doing whatever it did:

..
ext/mysql/.libs/php_mysql.o(.text+0x232d): In function `zif_mysql_create_db': /tmp/php-5.2.1/ext/mysql/php_mysql.c:1164: undefined reference  to `mysql_create_db'
ext/mysql/.libs/php_mysql.o(.text+0x2548): In function `zif_mysql_drop_db': /tmp/php-5.2.1/ext/mysql/php_mysql.c:1203: undefined reference  to `mysql_drop_db'
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1

Expected result:
----------------
Successful build.

Actual result:
--------------
See description.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-02-19 10:22 UTC] tony2001@php.net
Can't reproduce.
Which version of MySQL are you using?
 [2007-02-19 11:02 UTC] mikko dot kayhko at gmail dot com
MySQL server community edition 5.0.27.
 [2007-02-19 12:35 UTC] tony2001@php.net
I can't see any problems building PHP with MySQL 5.0.27 from RPMs.
Did you build MySQL yourself or did you use some binary packages?
It looks like you're using new libraries, but headers are from MySQL v.4.x.x. Please make sure you've installed new headers and removed the old ones.
 [2007-02-20 10:58 UTC] mikko dot kayhko at gmail dot com
Seems that the problem was because of old MySQL headers. Sorry for the inconvenience!
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Mon Jul 21 23:00:03 2025 UTC