无法在PHP 5.4中安装Xhprof [英] Can't install Xhprof in PHP 5.4

查看:148
本文介绍了无法在PHP 5.4中安装Xhprof的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在PHP 5.4中尝试使用xhprof时出现以下错误

I'm getting the following error when trying to use xhprof in PHP 5.4

PHP Warning:  PHP Startup: xhprof: Unable to initialize module
Module compiled with module API=20090626
PHP    compiled with module API=20100525

好像几天前安装5.4时,我与PHP版本有些冲突. php-v显示5.4,但是php-config --version显示5.3,phpize显示API = 20090626,而PHP是使用API​​ = 20100525编译的

It looks like I have some conflict with PHP versions as I installed 5.4 some days ago. php-v shows 5.4 but php-config --version shows 5.3 and phpize shows API=20090626 while PHP is compiled with API=20100525

推荐答案

sudo apt-get install php5-dev

在我的情况下,解决方案是升级软件包php5-dev.看来当我将php升级到5.4并没有升级php5-dev时,这就是php-config和phpize过时的原因.这样问题就解决了.

In my case the solution was to upgrade the package php5-dev. It looks like when I upgraded php to 5.4 didn't upgrade the php5-dev one, that's why php-config and phpize were outdated. So problem solved.

这篇关于无法在PHP 5.4中安装Xhprof的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆