I'm running a pile of mediawiki instances on Oracle enterprise Linux and I'm trying to upgrade from 1.19.x to the latest LTS version, 1.23.x. I'm currently using PHP 5.3 and due to some odd issues with special pages and thumbnails, it has been recommended that I upgrade PHP to 5.4 or higher.
./configure --prefix=$PRE --with-config-file-path=$CONFIG_FILE_PATH --with-mysql=/usr/include/mysql --with-apxs2=$PRE/apache/bin/apxs --with-zlib --with-jpeg-dir --with-gd --with-iconv-dir --with-libxml-dir=/usr/local/bin --enable-mbstring
the issue I have is that my compile of PHP keeps failing with error:
error: Cannot find MySQL header files under /usr/include/mysql.
here is where it gets odd:
$ cd /usr/include/mysql $ ll | grep mysql.h -rw-r--r-- 1 root root 28148 May 11 2011 mysql.h
clearly the header files are present.
here is where it gets even more odd: if I pull a copy of the PHP 5.3 tar, extract it and run the exact same compile command it succeeds.
I know that between PHP 5.3 and 5.4 PHP moved from libmysqlslient to mysqlnd [whatever that means], but according to their manual the compile arguments have not changed.
so I thought it must be the change to mysqlnd. so I tested that by compiling 5.3 with mysqlnd, and that succeeds!
I've also tried PHP 5.6 in case something broken was fixed, but that also fails with the cannot find header files error.
I'm at a loss of where to go from here.