php - 尝试安装 mcrypt 扩展时出错

标签 php centos mcrypt

我在 CentOS 下运行 PHP 5.4.23 版6.4 x64 并且正在尝试安装 mcrypt 扩展:

[root@user]# yum install php-mcrypt*
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: ftp.osuosl.org
 * epel: ftp.osuosl.org
 * extras: ftp.osuosl.org
 * updates: ftp.osuosl.org
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
--> Processing Dependency: php(zend-abi) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: php(api) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: libmcrypt.so.4()(64bit) for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Running transaction check
---> Package libmcrypt.x86_64 0:2.5.8-9.el6 will be installed
---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
--> Processing Dependency: php(zend-abi) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: php(api) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Finished Dependency Resolution
Error: Package: php-mcrypt-5.3.3-3.el6.x86_64 (epel)
           Requires: php(api) = 20090626
           Installed: php-common-5.4.23-1.el6.remi.x86_64 (@remi)
               php(api) = 20100412-x86-64
           Available: php-common-5.3.3-26.el6.x86_64 (base)
               php(api) = 20090626
           Available: php-common-5.3.3-27.el6_5.x86_64 (updates)
               php(api) = 20090626
Error: Package: php-mcrypt-5.3.3-3.el6.x86_64 (epel)
           Requires: php(zend-abi) = 20090626
           Installed: php-common-5.4.23-1.el6.remi.x86_64 (@remi)
               php(zend-abi) = 20100525-x86-64
           Available: php-common-5.3.3-26.el6.x86_64 (base)
               php(zend-abi) = 20090626
           Available: php-common-5.3.3-27.el6_5.x86_64 (updates)
               php(zend-abi) = 20090626
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

我该如何解决这个问题?

最佳答案

看起来您的 yum 库中的 php-mcrypt 版本适用于 PHP 5.3.3。

您的 PHP 版本是 5.4.23。试试这个:http://rpms.southbridge.ru/rhel6/php-5.4/x86_64/php-mcrypt-5.4.23-1.el6.remi.x86_64.rpm

从上面下载 RPM 并运行 rpm -ivh <name>

确保你已经单独安装了 libmcrypt。 Yum 安装所有依赖项,所以如果您使用 yum,它会安装 libmcrypt

关于php - 尝试安装 mcrypt 扩展时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20747166/

相关文章:

php - 如何在 DDEV 的 Web 容器中安装像 mcrypt 这样的 pecl 扩展?

php - 在外部 php 文件 Joomla 中包含 Jfactory 类

php - 将度数转换为 SVG 坐标

timer - 在 CentOS 上每 30 秒在后台运行一次命令

Python - pip install 找不到匹配的版本

linux - Kerberos 主从设置 : Database propagation, 和 KDC & KADMIN 切换

php - PHP 的 mcrypt 扩展是否符合 FIPS 197 标准?

php - fclose() : Argument #1 ($stream) must be of type resource, bool 给定

php - 有没有像chrome的时间线这样的php基准测试工具

php - 用 PHP 解密 AES CTR Little Endian