gpt4 book ai didi

PHP 5.3 上的 php_pdo_informix

转载 作者:可可西里 更新时间:2023-10-31 23:42:35 24 4
gpt4 key购买 nike

我有一个广泛使用 PDO 的 php 应用程序,并且有一个具有 informix 的新客户端。以前我们使用 php 5.2 没有任何问题,但切换到 PHP 5.3 是不可避免的,所以:

有人找到了在 php5.3 上使用 php_pdo_informix 的方法,还是它完全过时了,我必须找到另一种选择?

这对于我们的测试环境 (CentOS) 是必需的,但开发人员目前在 Windows 上工作,我们有类似的问题。有一个 php_pdo_informix.dll 但它是针对 php5.2 编译的并且拒绝在 php5.3 上加载

有人有php5.3的dll吗?

谢谢

我已经试过了:

$ sudo pecl install pdo_informix
pecl.php.net is using a unsupported protocol - This should never happen.
pecl/PDO_INFORMIX requires package "pear/PDO"
No valid packages found
install failed

pecl install --alldeps pdo_informix

显示它依赖于 pear/PDO 但它已在 5.3 中弃用

显式版本 1.2.6 、 1.2.7 无济于事

即使我尝试安装 pear/PDO,它也会失败并出现许多错误,这是预期的,因为 PHP 中有许多 API 更改会中断。

尝试预先安装pdo时出现这种错误:(省略部分行)

$ sudo pecl install  pdo
WARNING: "pecl/PDO" is deprecated in favor of "channel://http://svn.php.net/viewvc/php/php-src/trunk/ext/pdo//ext/PDO"
downloading PDO-1.0.3.tgz ...
Starting to download PDO-1.0.3.tgz (52,613 bytes)
.............done: 52,613 bytes
12 source files, building
<...more lines ...>
/tmp/pear/temp/PDO/pdo_dbh.c: In function 'pdo_stmt_instantiate':
/tmp/pear/temp/PDO/pdo_dbh.c:410:8: error: 'zval' has no member named 'refcount'
/tmp/pear/temp/PDO/pdo_dbh.c:411:8: error: 'zval' has no member named 'is_ref'
/tmp/pear/temp/PDO/pdo_dbh.c: In function 'pdo_stmt_construct':
/tmp/pear/temp/PDO/pdo_dbh.c:435:6: error: 'zend_fcall_info' has no member named 'object_pp'
/tmp/pear/temp/PDO/pdo_dbh.c:458:6: error: 'zend_fcall_info_cache' has no member named 'object_pp'
/tmp/pear/temp/PDO/pdo_dbh.c: In function 'zim_PDO_setAttribute':
/tmp/pear/temp/PDO/pdo_dbh.c:752:12: error: 'zval' has no member named 'refcount'
/tmp/pear/temp/PDO/pdo_dbh.c: In function 'zim_PDO_getAttribute':
/tmp/pear/temp/PDO/pdo_dbh.c:818:28: error: 'zval' has no member named 'refcount'
/tmp/pear/temp/PDO/pdo_dbh.c: In function 'pdo_hash_methods':
/tmp/pear/temp/PDO/pdo_dbh.c:1122:24: warning: assignment discards 'const' qualifier from pointer target type [enabled by default]
/tmp/pear/temp/PDO/pdo_dbh.c:1126:20: warning: assignment discards 'const' qualifier from pointer target type [enabled by default]
make: *** [pdo_dbh.lo] Error 1
ERROR: `make' failed

如果我尝试安装特定的 pdo_informix 版本,我会得到以下输出:

pecl install --alldeps  http://pecl.php.net/get/PDO_INFORMIX-1.2.6.tgz 
downloading PDO_INFORMIX-1.2.6.tgz ...
Starting to download PDO_INFORMIX-1.2.6.tgz (65,676 bytes)
.................done: 65,676 bytes
WARNING: "pecl/PDO" is deprecated in favor of "channel://http://svn.php.net/viewvc/php/php- src/trunk/ext/pdo//ext/PDO"
downloading PDO-1.0.3.tgz ...
Starting to download PDO-1.0.3.tgz (52,613 bytes)
...done: 52,613 bytes
12 source files, building
running: phpize
Configuring for:
PHP Api Version: 20090626
Zend Module Api No: 20090626
Zend Extension Api No: 220090626
<more lines>
<same output as above>

最佳答案

PDO是核心的一部分;无需从 pecl 安装。

可能是您必须安装 您的 linux 发行版 的 php-pdo-informix 软件包,例如通过 apt-getyum

关于PHP 5.3 上的 php_pdo_informix,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11892926/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com