So che ci sono diverse istanze di questa domanda su StackOverflow ma non sto trovando una soluzione.Impossibile installare PDO su CentOS
Sto facendo funzionare CentOS con Apache e PHP 5.3
Uno script .php mi sta dando questo errore:
Fatal error: Class 'PDO' not found in ...
mi sono imbattuto phpinfo();
e l'unico posto "DOP" esiste la pagina è in la riga "Configure Command" '--disable-pdo'
.
Ho tentato #yum install php-pdo
ma non esistono pacchetti.
Ho anche tentato #pecl install pdo
e ottengo questi errori alla fine:
/root/tmp/pear/PDO/pdo_dbh.c: In function 'pdo_stmt_instantiate':
/root/tmp/pear/PDO/pdo_dbh.c:410: error: 'zval' has no member named 'refcount'
/root/tmp/pear/PDO/pdo_dbh.c:411: error: 'zval' has no member named 'is_ref'
/root/tmp/pear/PDO/pdo_dbh.c: In function 'pdo_stmt_construct':
/root/tmp/pear/PDO/pdo_dbh.c:435: error: 'zend_fcall_info' has no member named 'object_pp'
/root/tmp/pear/PDO/pdo_dbh.c:458: error: 'zend_fcall_info_cache' has no member named 'object_pp'
/root/tmp/pear/PDO/pdo_dbh.c: In function 'zim_PDO_setAttribute':
/root/tmp/pear/PDO/pdo_dbh.c:752: error: 'zval' has no member named 'refcount'
/root/tmp/pear/PDO/pdo_dbh.c: In function 'zim_PDO_getAttribute':
/root/tmp/pear/PDO/pdo_dbh.c:818: error: 'zval' has no member named 'refcount'
/root/tmp/pear/PDO/pdo_dbh.c: In function 'pdo_hash_methods':
/root/tmp/pear/PDO/pdo_dbh.c:1122: warning: assignment discards qualifiers from pointer target type
/root/tmp/pear/PDO/pdo_dbh.c:1126: warning: assignment discards qualifiers from pointer target type
make: *** [pdo_dbh.lo] Error 1
ERROR: `make' failed
Poi sul doc php.net fondamentalmente dice il pacchetto viene fornito di serie in installazioni php a partire da PHP 5.1.
Ho aggiunto la riga extension=pdo.so
a php.ini e riavviato Apache e il problema persiste. Eventuali suggerimenti?
'php-pdo' è il nome corretto del pacchetto per CentOS. Si presenta se fai 'yum search php-pdo'? –
gli unici risultati che ottengo per yum search pdo sono un sacco di pacchetti "casenoupdown". ho anche eseguito yum clean all e yum update recentemente – chuckieDub
forse questo è il mio problema http://serverfault.com/questions/511779/cant-install-php-pdo – chuckieDub