php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #61859 pdo fails on make
Submitted: 2012-04-26 19:55 UTC Modified: 2020-11-22 04:22 UTC
Votes:12
Avg. Score:4.8 ± 0.6
Reproduced:10 of 11 (90.9%)
Same Version:2 (20.0%)
Same OS:8 (80.0%)
From: gencer at cmail dot cm Assigned: cmb (profile)
Status: No Feedback Package: Compile Failure
PHP Version: 5.4.1 OS: CentOS 5.8 x86_64
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: gencer at cmail dot cm
New email:
PHP Version: OS:

 

 [2012-04-26 19:55 UTC] gencer at cmail dot cm
Description:
------------
PDO (mysql, pgsql, mssql, sqlite ...) fails on make.

After i update my Centos to the latest version i got these errors...

When i configure (./configure) i changed the pdo, pdo_mysql, pdo_sqlite directories and .h files inside them:

#include "pdo/php_pdo.h"
#include "pdo/php_pdo_driver.h"

to

#include "ext/pdo/php_pdo.h"
#include "ext/pdo/php_pdo_driver.h"

And it worked.

Expected result:
----------------
make should build fine

Actual result:
--------------
/installers/php/php-5.4.1/ext/pdo_pgsql/pdo_pgsql.c:28:25: error: pdo/php_pdo.h: No such file or directory
/installers/php/php-5.4.1/ext/pdo_pgsql/pdo_pgsql.c:29:32: error: pdo/php_pdo_driver.h: No such file or directory

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-04-26 20:04 UTC] gencer at cmail dot cm
-Package: PDO related +Package: Compile Failure
 [2012-04-26 20:04 UTC] gencer at cmail dot cm
Switched to the Compile Failure.
Issue seems to be applied on all version of PHP 5.4 with updated CentOS 5.8.
 [2012-04-30 21:08 UTC] sixd@php.net
-Status: Open +Status: Feedback
 [2012-04-30 21:08 UTC] sixd@php.net
What were the original configure options (and other commands, if any) you used 
that produced the failure?
 [2012-05-01 06:44 UTC] gencer at cmail dot cm
Here is the full configure pattern:

'./configure' '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--cache-file=../config.cache' '--with-libdir=lib64' '--with-config-file-path=/etc' '--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' '--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' '--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-pcre-regex' '--with-zlib' '--with-layout=GNU' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--with-kerberos' '--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' '--with-libxml-dir=/usr' '--enable-libxml' '--with-xmlrpc' '--enable-xml' '--with-system-tzdata' '--with-mhash' '--with-mysql' '--with-gd' '--enable-dom' '--disable-dba' '--without-unixODBC--disable-xmlreader' '--disable-xmlwriter' '--without-sqlite' '--with-sqlite3' '--enable-phar' '--enable-fileinfo' '--enable-json' '--without-pspell' '--disable-wddx' '--without-curl' '--disable-posix' '--disable-sysvmsg' '--disable-sysvshm' '--disable-sysvsem' '--enable-pdo' '--enable-mbstring' '--enable-fastcgi' '--with-mcrypt' '--enable-fpm' '--with-mysqli=/usr/bin/mysql_config' '--with-pdo-mysql' '--enable-pcntl' '--with-imap=../imap/imap-2007f' '--with-imap-ssl' '--with-pgsql=/usr/pgsql-9.1' '--with-pdo-pgsql=/usr/pgsql-9.1'

Please allow me to remind this. This is not only for postgresql also pdo_mysql and pdo_sqlite too.

These errors happend to me after i updated/upgraded my linux system to the latest updates/versions. (like gcc, glibc etc.) All updates are stable and released by CentOS (but not by other 3rd parties).

Few weeks ago i havd no errors with this. But now i have.
 [2012-06-16 09:01 UTC] paszczak000 at gmail dot com
The same error I have on CentOS release 6.2 (Final) - 2.6.32-220.13.1.el6.centos.plus.x86_64.

./configure --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info --cache-file=../config.cache --with-libdir=lib64 --with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d --disable-debug --with-pic --disable-rpath --without-pear --with-bz2 --with-curl --with-freetype-dir=/usr --with-gd --enable-gd-jis-conv --enable-gd-native-ttf --with-gdbm --with-gmp --enable-mbstring --with-iconv --with-jpeg-dir=/usr --with-pspell -with-zlib --with-zlib-dir=/usr/include --with-layout=GNU --enable-exif --enable-ftp --enable-sockets --enable-sysvsem --enable-sysvshm --enable-sysvmsg --enable-wddx --with-unixODBC=shared,/usr --enable-shmop --enable-calendar --without-sqlite3 --without-pdo-sqlite --with-libxml-dir=/usr --with-mhash --with-mcrypt --with-apxs2 --disable-dba --without-unixODBC --enable-json --with-mysql --with-mysqli --enable-soap --with-imap-ssl --with-imap --with-openssl --with-kerberos --enable-bcmath --with-pdo-mysql --with-pear=/usr/lib/php --with-gettext

But version PHP 5.4.1 with the same options in compiling very well.
 [2012-08-21 07:45 UTC] paszczak000 at gmail dot com
The same result with: 5.4.6 on CentOS release 6.3 (Final).
 [2012-08-21 08:24 UTC] gencer at cmail dot cm
@paszczak000

It is all because of GLIBC and GCC. Make sure that you have autoconf installed. Re unpack tar.gz and recompile again. If this bug still exist manually change pdo/ with ext/pdo in .h files.

I hope this helps.

(yum install glibc gcc glibc-devel autoconf)
 [2012-08-21 08:28 UTC] paszczak000 at gmail dot com
Package glibc-2.12-1.80.el6_3.4.x86_64 already installed and latest version
Package gcc-4.4.6-4.el6.x86_64 already installed and latest version
Package glibc-devel-2.12-1.80.el6_3.4.x86_64 already installed and latest version
Package autoconf-2.63-5.1.el6.noarch already installed and latest version

Manually changing dirs helps, but this is workaround.
 [2012-08-21 08:52 UTC] aharvey@php.net
-Status: Feedback +Status: Open
 [2013-03-22 04:39 UTC] mike at tetonapps dot com
I had this exact problem with version 5.4.13 when attempting to compile in 
Amazon Linux (which is basically CentOS 5, and I turned off php* in the yum repo 
config.)

I solved it more easily by simply by adding soft links so that I would not have 
to modify any files:
php-5.4.13/pdo/php_pdo.h points to php-5.4.13/ext/pdo/php_pdo.h
php-5.4.13/pdo/php_pdo_driver.h points to php-5.4.13/ext/pdo/php_pdo_driver.h

After adding these two symbolic links, PHP compiled and installed properly.
 [2013-09-09 16:57 UTC] austin dot bischoff at gmail dot com
I just had this issue on two separate CentOS release 6.4 (Final) servers trying to install and compile php 5.4.19.

The ln -s solution worked for me but I just did "ln -s ./ext/pdo" in the root of the extracted source files. Once I did 
this the compile and install completed as expected.
 [2013-09-22 03:54 UTC] jose dot nobile at gmail dot com
I have 2 Centos Servers 6.4 (Final), the second with was updated with yum 
update, doesn't exists any additional repository different of CentOS 
repositories.

In the first server PHP compile fine, in the second not.
The first is not updated, but yum show the next will be updated (it can help 
you)

Installing:
 kernel                                         x86_64                   2.6.32-
358.18.1.el6                                    updates                               
26 M
 kernel-devel                                   x86_64                   2.6.32-
358.18.1.el6                                    updates                              
8.2 M
Updating:
 bind                                           x86_64                   
32:9.8.2-0.17.rc1.el6_4.6                              updates                              
4.0 M
 bind-chroot                                    x86_64                   
32:9.8.2-0.17.rc1.el6_4.6                              updates                               
71 k
 bind-libs                                      x86_64                   
32:9.8.2-0.17.rc1.el6_4.6                              updates                              
878 k
 bind-utils                                     x86_64                   
32:9.8.2-0.17.rc1.el6_4.6                              updates                              
182 k
 busybox                                        x86_64                   
1:1.15.1-16.el6_4                                      updates                              
611 k
 cpuspeed                                       x86_64                   1:1.5-
20.el6_4                                         updates                               
37 k
 db4                                            x86_64                   4.7.25-
18.el6_4                                        updates                              
563 k
 db4-cxx                                        x86_64                   4.7.25-
18.el6_4                                        updates                              
588 k
 db4-devel                                      x86_64                   4.7.25-
18.el6_4                                        updates                              
6.6 M
 db4-utils                                      x86_64                   4.7.25-
18.el6_4                                        updates                              
130 k
 device-mapper-multipath                        x86_64                   0.4.9-
64.el6_4.2                                       updates                              
112 k
 device-mapper-multipath-libs                   x86_64                   0.4.9-
64.el6_4.2                                       updates                              
175 k
 dhclient                                       x86_64                   
12:4.1.1-34.P1.el6_4.1                                 updates                              
316 k
 dhcp                                           x86_64                   
12:4.1.1-34.P1.el6_4.1                                 updates                              
816 k
 dhcp-common                                    x86_64                   
12:4.1.1-34.P1.el6_4.1                                 updates                              
141 k
 glibc                                          i686                     2.12-
1.107.el6_4.4                                     updates                              
4.3 M
 glibc                                          x86_64                   2.12-
1.107.el6_4.4                                     updates                              
3.8 M
 glibc-common                                   x86_64                   2.12-
1.107.el6_4.4                                     updates                               
14 M
 glibc-devel                                    x86_64                   2.12-
1.107.el6_4.4                                     updates                              
974 k
 glibc-headers                                  x86_64                   2.12-
1.107.el6_4.4                                     updates                              
605 k
 hplip-common                                   x86_64                   3.12.4-
4.el6_4.1                                       updates                               
74 k
 httpd                                          x86_64                   2.2.15-
29.el6.centos                                   updates                              
821 k
 httpd-devel                                    x86_64                   2.2.15-
29.el6.centos                                   updates                              
150 k
 httpd-manual                                   noarch                   2.2.15-
29.el6.centos                                   updates                              
783 k
 httpd-tools                                    x86_64                   2.2.15-
29.el6.centos                                   updates                               
73 k
 kernel-doc                                     noarch                   2.6.32-
358.18.1.el6                                    updates                               
10 M
 kernel-firmware                                noarch                   2.6.32-
358.18.1.el6                                    updates                               
11 M
 kernel-headers                                 x86_64                   2.6.32-
358.18.1.el6                                    updates                              
2.3 M
 kpartx                                         x86_64                   0.4.9-
64.el6_4.2                                       updates                               
54 k
 krb5-devel                                     x86_64                   1.10.3-
10.el6_4.6                                      updates                              
495 k
 krb5-libs                                      x86_64                   1.10.3-
10.el6_4.6                                      updates                              
761 k
 krb5-workstation                               x86_64                   1.10.3-
10.el6_4.6                                      updates                              
805 k
 libipa_hbac                                    x86_64                   1.9.2-
82.10.el6_4                                      updates                               
80 k
 libipa_hbac-python                             x86_64                   1.9.2-
82.10.el6_4                                      updates                               
75 k
 libsss_autofs                                  x86_64                   1.9.2-
82.10.el6_4                                      updates                               
84 k
 libsss_idmap                                   x86_64                   1.9.2-
82.10.el6_4                                      updates                               
83 k
 mdadm                                          x86_64                   3.2.5-
4.el6_4.2                                        updates                              
334 k
 microcode_ctl                                  x86_64                   1:1.17-
15.el6_4                                        updates                              
611 k
 mod_ssl                                        x86_64                   
1:2.2.15-29.el6.centos                                 updates                               
90 k
 neon                                           x86_64                   0.29.3-
3.el6_4                                         updates                              
119 k
 net-snmp                                       x86_64                   1:5.5-
44.el6_4.4                                       updates                              
303 k
 net-snmp-devel                                 x86_64                   1:5.5-
44.el6_4.4                                       updates                              
302 k
 net-snmp-libs                                  x86_64                   1:5.5-
44.el6_4.4                                       updates                              
1.5 M
 net-snmp-perl                                  x86_64                   1:5.5-
44.el6_4.4                                       updates                              
320 k
 net-snmp-python                                x86_64                   1:5.5-
44.el6_4.4                                       updates                               
71 k
 net-snmp-utils                                 x86_64                   1:5.5-
44.el6_4.4                                       updates                              
172 k
 openswan                                       x86_64                   2.6.32-
21.el6_4                                        updates                              
894 k
 perf                                           x86_64                   2.6.32-
358.18.1.el6                                    updates                              
2.1 M
 polkit                                         x86_64                   0.96-
5.el6_4                                           updates                              
158 k
 polkit-desktop-policy                          noarch                   0.96-
5.el6_4                                           updates                              
6.9 k
 polkit-devel                                   x86_64                   0.96-
5.el6_4                                           updates                               
27 k
 polkit-docs                                    x86_64                   0.96-
5.el6_4                                           updates                              
272 k
 prelink                                        x86_64                   0.4.6-
3.1.el6_4                                        updates                              
993 k
 qemu-img                                       x86_64                   
2:0.12.1.2-2.355.0.1.el6.centos.7                      updates                              
472 k
 qemu-kvm                                       x86_64                   
2:0.12.1.2-2.355.0.1.el6.centos.7                      updates                              
1.3 M
 qemu-kvm-tools                                 x86_64                   
2:0.12.1.2-2.355.0.1.el6.centos.7                      updates                              
295 k
 rsyslog                                        x86_64                   5.8.10-
7.el6_4                                         updates                              
648 k
 sos                                            noarch                   2.2-
38.el6.centos.2                                    updates                              
224 k
 spice-server                                   x86_64                   0.12.0-
12.el6_4.3                                      updates                              
326 k
 sssd-client                                    x86_64                   1.9.2-
82.10.el6_4                                      updates                              
119 k
 wbm-server-manager                             noarch                   
7.2.kvm-1                                              cloudmin-universal                   
1.4 M
 wbt-virtual-server-theme                       noarch                   2:8.8-1                                                
cloudmin-universal                   2.3 M
 webmin                                         noarch                   1.650-1                                                
cloudmin-universal                    21 M

The configure is
'./configure' '--target=x86_64-redhat-linux-gnu'  '--build=x86_64-redhat-linux-
gnu' '--host=x86_64-redhat-linux-gnu' '--with-layout=GNU' '--enable-layout=GNU' 
'--with-libdir=lib64' '--
cache-file=../config.cache' '--bindir=/usr/bin' '--datadir=/usr/share' '--exec-
prefix=/usr' '--includedir=/usr/include' '--infodir=/usr/share/info' '--
libdir=/usr/lib64' '--
libexecdir=/usr/libexec' '--localstatedir=/var' '--mandir=/usr/share/man' '--
prefix=/usr' '--program-prefix=' '--sbindir=/usr/sbin' '--
sharedstatedir=/usr/com' '--sysconfdir=/etc' '--
with-config-file-path=/etc' '--with-config-file-scan-dir=/etc/php.d' '--enable-
fpm' '--enable-maintainer-zts' '--disable-rpath' '--enable-mysqlnd' '--enable-
bcmath' '--enable-calendar' 
'--enable-dba=shared' '--enable-dom' '--enable-exif' '--enable-ftp' '--enable-
gd-jis-conv' '--enable-gd-native-ttf' '--enable-intl' '--enable-mbregex' '--
enable-mbstring' '--enable-
pcntl' '--enable-shmop' '--enable-soap'  '--enable-soap=shared' '--enable-
sockets' '--enable-static' '--enable-sysvmsg' '--enable-sysvsem' '--enable-
sysvshm' '--enable-wddx' '--enable-
zip'  '--with-pdo-mysql=mysqlnd' '--with-mysql-sock=/var/lib/mysql/mysql.sock' 
'--with-mysql=mysqlnd' '--with-mysqli=mysqlnd' '--with-pdo-
odbc=shared,unixODBC,/usr' '--with-pdo-
pgsql=shared,/usr/pgsql-9.2/bin' '--with-pdo-sqlite=shared,/usr' '--with-
pgsql=shared,/usr/pgsql-9.2/bin'  '--with-unixODBC=shared,/usr' '--with-pic' '--
with-png-dir=/usr' '--with-
pspell' '--with-recode' '--with-snmp'  '--with-bz2' '--with-curl' '--with-
db4=/usr' '--with-freetype-dir=/usr' '--with-gd' '--with-gettext' '--with-gmp' 
'--with-iconv' '--with-jpeg-
dir=/usr' '--with-kerberos' '--with-ldap' '--with-ldap-sasl' '--with-libmbfl' '-
-with-libxml-dir=/usr' '--with-mcrypt' '--with-mhash' '--with-onig' '--with-
openssl'  '--with-pcre-
regex=/usr' '--with-t1lib' '--with-tidy'  '--with-xmlrpc' '--with-xsl' '--with-
xsl=shared,/usr' '--with-zlib' '--enable-opcache'

/bin/sh /root/php-5.5.4/libtool --silent --preserve-dup-deps --mode=compile 
/root/php-5.5.4/meta_ccld -I/root/php-5.5.1/ext  -I/usr/include -
DPDO_ODBC_TYPE=\"unixODBC\" -Iext/pdo_odbc/ 
-I/root/php-5.5.4/ext/pdo_odbc/ -DPHP_ATOM_INC -I/root/php-5.5.4/include -
I/root/php-5.5.4/main -I/root/php-5.5.4 -I/root/php-5.5.4/ext/date/lib -
I/root/php-5.5.4/ext/ereg/regex -
I/usr/include/libxml2 -I/usr/local/include -I/usr/include/freetype2 -I/root/php-
5.5.4/ext/mbstring/oniguruma -I/root/php-5.5.4/ext/mbstring/libmbfl -I/root/php-
5.5.4/ext/mbstring/libmbfl/mbfl -I/usr/pgsql-9.2/include -I/usr/include/pspell -
I/usr/local/include/tidy -I/root/php-5.5.4/TSRM -I/root/php-5.5.4/Zend  -
D_REENTRANT  -I/usr/include -g 
-O2 -fvisibility=hidden -pthread -DZTS  -prefer-pic -c /root/php-
5.5.4/ext/pdo_odbc/pdo_odbc.c -o ext/pdo_odbc/pdo_odbc.lo
/root/php-5.5.4/ext/pdo_odbc/pdo_odbc.c:28:25: error: pdo/php_pdo.h: No such 
file or directory
/root/php-5.5.4/ext/pdo_odbc/pdo_odbc.c:29:32: error: pdo/php_pdo_driver.h: No 
such file or directory


Can you say why to apply the standard yum update produce these error?

I want keep updated with the lastest PHP releases!
 [2013-10-17 13:43 UTC] jose dot nobile at gmail dot com
Still the problem with lastest stable PHP version 5.5.5
 [2017-07-10 08:55 UTC] clement dot turbelin at gmail dot com
Same problem on CentOS 6.9 trying to compile php 5.6.36
 [2020-11-11 14:02 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2020-11-11 14:02 UTC] cmb@php.net
Is this still an issue with any of the actively supported PHP
versions[1]?

[1] <https://www.php.net/supported-versions.php>
 [2020-11-22 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Nov 05 19:01:29 2024 UTC