如何安装 php-devel

如何安装 php-devel

当我尝试运行时,我总是遇到依赖问题yum install php-devel

yum 安装 --skip-broken php-devel

....
--> Finished Dependency Resolution
php-5.1.6-32.el5.i386 from base has depsolving problems
  --> Missing Dependency: php-common = 5.1.6-32.el5 is needed by package php-5.1.6-32.el5.i386 (base)
php-cli-5.1.6-32.el5.i386 from base has depsolving problems
  --> Missing Dependency: php-common = 5.1.6-32.el5 is needed by package php-cli-5.1.6-32.el5.i386 (base)
--> Running transaction check
---> Package php.i386 0:5.1.6-32.el5 set to be updated
--> Processing Dependency: php = 5.1.6-32.el5 for package: php-devel
---> Package php-cli.i386 0:5.1.6-32.el5 set to be updated
--> Finished Dependency Resolution
php-devel-5.1.6-32.el5.i386 from base has depsolving problems
  --> Missing Dependency: php = 5.1.6-32.el5 is needed by package php-devel-5.1.6-32.el5.i386 (base)

Packages skipped because of dependency problems:
    autoconf-2.59-12.noarch from base
    automake-1.9.6-2.3.el5.noarch from base
    imake-1.0.2-3.i386 from base
    php-5.1.6-32.el5.i386 from base
    php-cli-5.1.6-32.el5.i386 from base
    php-devel-5.1.6-32.el5.i386 from base

有任何想法吗?

答案1

为什么您不想安装依赖项? yum 会向您显示安装所需的依赖项。 否则,如果您只想要这一个包,您不妨只使用 .rpm。

答案2

根据错误消息 - 您缺少 php-common 包来满足 yum 安装程序的要求。您可能需要尝试清理缓存 (yum clean all) 并重新运行 yum install php-devel 命令。

也许提供 php-common 的 repo 被禁用了?(yum repolist all)?

更新

还要确保您正在为正确的架构安装... uname -r。要强制为特定架构安装软件包,您可以:yum install php-devel.x86_64

相关内容