PHP 5.1 and 5.2 and MySQL 5.1.20+
Today I fell victim of a gotcha when custom compiling PHP 5.1.4 for a customer which runs MySQL 5.1.22. The customer in question requires the mysqli component which appears to be broken with these versions (fixed in 5.2.4 though). So if you configure PHP with --with-mysqli=/usr/bin/mysql_config
enabled you will soon find yourself staring at:
1 2 3 4 5 6 |
|
To fix this, either upgrade to 5.2.4, or if you’re left with no choice such as myself edit php-5.1.4/ext/mysqli/mysqli_api.c
and replace all occurrances of gptr
with char*
That ought to get you through the rest of the compilation provided that you’ve got the rest of your setup correct.