php5-dev missing mysqlnd header files

Bug #1056072 reported by Steven Dickinson
26
This bug affects 5 people
Affects Status Importance Assigned to Milestone
php5 (Debian)
Fix Released
Unknown
php5 (Ubuntu)
Triaged
Medium
Unassigned

Bug Description

The php5-dev package does not include the mysqlnd header files, and therefore pecl installation of mysqlnd plugins fails.

The php5-mysqlnd package does not include the header files.

Reproduction:

$ sudo apt-get install php5-mysqlnd php5-dev
(installing dependencies, assuming that worked)
$ sudo pecl install mysqlnd_qc
(answer "no" to storage engine questions)

Shortly the compile fails, file "php5/ext/mysqlnd/php_mysqlnd.h" missing - in fact, the expected /usr/include/php5/ext/mysqlnd folder is missing.

This can be manually fixed by using apt-get source and dpkg-buildpackage to build the php5 packages locally, and then copying the include folder from the build outputs.

$ lsb_release -rd
Description: Ubuntu 12.04.1 LTS
Release: 12.04

$ apt-cache policy php5-dev
php5-dev:
  Installed: 5.3.10-1ubuntu3.4
  Candidate: 5.3.10-1ubuntu3.4
  Version table:
 *** 5.3.10-1ubuntu3.4 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise-updates/main amd64 Packages
        500 http://security.ubuntu.com/ubuntu/ precise-security/main amd64 Packages
        100 /var/lib/dpkg/status
     5.3.10-1ubuntu3 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages

$ apt-cache policy php5-mysqlnd
php5-mysqlnd:
  Installed: 5.3.10-1ubuntu3.4
  Candidate: 5.3.10-1ubuntu3.4
  Version table:
 *** 5.3.10-1ubuntu3.4 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise-updates/universe amd64 Packages
        500 http://security.ubuntu.com/ubuntu/ precise-security/universe amd64 Packages
        100 /var/lib/dpkg/status
     5.3.10-1ubuntu3 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise/universe amd64 Packages

Tags: precise
Thomas Ward (teward)
tags: added: precise
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

This seems like a legitimate problem. I spent a little while trying to see an easy solution but the build process for this package is *really* complex, so hopefully the Debian maintainers can help sort it out. Seems to be as far as I can take it, so marking Triaged and Medium, as this only affects users who want to compile things dependent on these particular headers.

Changed in php5 (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Changed in php5 (Debian):
status: Unknown → New
Revision history for this message
Eran Uzan (etherpulse) wrote :

This also affects mysqlnd_ms compilation when installing from pecl repo's as it fails with :
$sudo pecl install mysqlnd_ms
.
.
.
libtool: compile: cc -I. -I/tmp/pear/temp/mysqlnd_ms -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-rootAFAq3S/mysqlnd_ms-1.5.2/include -I/tmp/pear/temp/pear-build-rootAFAq3S/mysqlnd_ms-1.5.2/main -I/tmp/pear/temp/mysqlnd_ms -I/usr/include/php5 -I/usr/include/php5/main -I/usr/include/php5/TSRM -I/usr/include/php5/Zend -I/usr/include/php5/ext -I/usr/include/php5/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c
/tmp/pear/temp/mysqlnd_ms/php_mysqlnd_ms.c -fPIC -DPIC -o .libs/php_mysqlnd_ms.o

/tmp/pear/temp/mysqlnd_ms/php_mysqlnd_ms.c:28:33: fatal error: ext/mysqlnd/mysqlnd.h: No such file or directory
compilation terminated.
make: *** [php_mysqlnd_ms.lo] Error 1
ERROR: `make' failed

Revision history for this message
Ondřej Surý (ondrej) wrote :

This will be fixed in next upload of PHP 5.5 to Debian unstable. I am just working on an optimal fix.

Changed in php5 (Debian):
status: New → Fix Released
Revision history for this message
Ofer Cohen (oc666) wrote :

Thanks for take care of this bug!!!
When will it be in Ubuntu repos?

Revision history for this message
Ondřej Surý (ondrej) wrote :

No problem, it has been on my TODO list to get it fixed after php5 transition to Debian testing.

For Ubuntu I guess that it will be in saucy.

(Or you can use my PPAs to get newest PHP 5.4 / PHP 5.5 version - see my launchpad page or debphp.org).

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.