Bug #59636 Can't build with libmysql from 5.5.8 - wrong include paths in the source
Submitted: 20 Jan 2011 14:13 Modified: 21 Jan 2011 6:42
Reporter: Andrey Hristov Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server: Installing Severity:S2 (Serious)
Version:5.5.8 OS:Any
Assigned to: CPU Architecture:Any

[20 Jan 2011 14:13] Andrey Hristov
Description:
I am trying to build PHP with libmysql installed from source server distribution. The installation is under /usr/local/mysql . mysql_config from /usr/local/mysql/bin/mysql_config is being used. There is no other libmysql or connector/c installed on the system.
Here is the error:
In file included from /usr/local/mysql/include/my_sys.h:47,
                 from /php/trunk/ext/mysqli/php_mysqli_structs.h:79,
                 from /php/trunk/ext/mysqli/mysqli.c:33:
/usr/local/mysql/include/my_pthread.h:829: fatal error: mysql/psi/mysql_thread.h: No such file or directory

I have the mysql_thread.h file, but it is not under mysql/psi/ but here:
andrey@poohie:/php/trunk$  ls -al /usr/local/mysql/include/psi/mysql_thread.h
-rw-r--r-- 1 root root 28626 2010-12-03 18:58 /usr/local/mysql/include/psi/mysql_thread.h

The include path in the server sources is wrong.

How to repeat:
See above.

Suggested fix:
Fix it!
[20 Jan 2011 14:16] Andrey Hristov
An workaround is to create a symlink in /usr/local/mysql/include to fix temporarily this, but this is not real solution:

root@poohie:/usr/local/mysql/include# ln -s . mysql
[21 Jan 2011 6:42] Valeriy Kravchuk
This is a duplicate of Bug #51925.