[英]Can't install php-xml for PHP7 (CentOS)
我已经安装了 PHP7,我想安装 php-xml,但它不会让我,因为我的系统上仍然有 PHP 5.4 的冲突痕迹,我无法摆脱。
这是我尝试运行“yum install php-xml”时的样子:
$ sudo yum install php-xml Loaded plugins: fastestmirror, langpacks, replace Loading mirror speeds from cached hostfile * base: mirror.fileplanet.com * epel: mirror.sjc02.svwh.net * extras: mirror.fileplanet.com * ius: mirrors.kernel.org * remi-safe: mirrors.mediatemple.net * rpmfusion-free-updates: mirror.math.princeton.edu * rpmfusion-nonfree-updates: mirror.math.princeton.edu * updates: mirror.fileplanet.com * webtatic: us-east.repo.webtatic.com Resolving Dependencies --> Running transaction check ---> Package php-xml.x86_64 0:5.4.16-42.el7 will be installed --> Processing Dependency: php-common(x86-64) = 5.4.16-42.el7 for package: php-xml-5.4.16-42.el7.x86_64 --> Running transaction check ---> Package php-common.x86_64 0:5.4.16-42.el7 will be installed --> Processing Conflict: php70w-common-7.0.19-1.w7.x86_64 conflicts php-common Finished Dependency Resolution Error: php70w-common conflicts with php-common-5.4.16-42.el7.x86_64 You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest
我什至试图删除 php-common ,我只是得到:
$ sudo yum remove php-common-5.4.16-42.el7.x86_64 Loaded plugins: fastestmirror, langpacks, replace No Match for argument: php-common-5.4.16-42.el7.x86_64 No Packages marked for removal
所以它与 php-common-5.4.16-42.el7.x86_64 冲突,但 php-common-5.4.16-42.el7.x86_64 不存在。
任何帮助是极大的赞赏。
另外,我注意到它说
<code>
Package php-xml.x86_64 0:5.4.16-42.el7 will be installed
</code>
但我不希望它用于 php 5.4,我想要它用于 PHP7。
由于您已经安装了webtatic repo ,那些 php 安装应该是php70w-<package>
。
yum install php70w-xml
应该可以解决问题。
在 Centos7 上,这适用于我的情况:
yum install php-xml
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.