我的php版本是5.4
这是我在 phpinfo 中得到的信息
pdo_sqlite
PDO Driver for SQLite 3.x enabled
SQLite Library 3.6.20
我确实需要更新这个驱动程序。
在 PHP 5.3 中,你可以使用以下命令执行此操作yum 安装 php5-sqlite,但现在看来我必须使用 pecl。
对于命令pecl 安装 pdo_sqlite,我得到了这个:
/var/tmp/PDO_SQLITE/sqlite_driver.c: In function 'do_callback':
/var/tmp/PDO_SQLITE/sqlite_driver.c:311: error: 'zend_fcall_info' has no member named 'object_pp'
/var/tmp/PDO_SQLITE/sqlite_driver.c: At top level:
/var/tmp/PDO_SQLITE/sqlite_driver.c:636: warning: initialization from incompatible pointer type
/var/tmp/PDO_SQLITE/sqlite_driver.c: In function 'make_filename_safe':
/var/tmp/PDO_SQLITE/sqlite_driver.c:645: error: 'struct _php_core_globals' has no member named 'safe_mode'
/var/tmp/PDO_SQLITE/sqlite_driver.c:645: error: 'CHECKUID_CHECK_FILE_AND_DIR' undeclared (first use in this function)
/var/tmp/PDO_SQLITE/sqlite_driver.c:645: error: (Each undeclared identifier is reported only once
/var/tmp/PDO_SQLITE/sqlite_driver.c:645: error: for each function it appears in.)
/var/tmp/PDO_SQLITE/sqlite_driver.c: In function 'pdo_sqlite_handle_factory':
/var/tmp/PDO_SQLITE/sqlite_driver.c:720: error: 'struct _php_core_globals' has no member named 'safe_mode'
make: *** [sqlite_driver.lo] Error 1
ERROR: `make' failed
您如何解决这个问题?如果可能的话,我不想重新编译 php - 这可能会给生产服务器带来一些问题。
我的服务器是 CentOS 版本 6.4
谢谢