centos 下安装xdebug以便netbeans调试PHP
来源:互联网 发布:怎么开通淘宝直通车 编辑:程序博客网 时间:2024/04/30 07:08
xdebug官方网站没有.tar.gz的文件,只有源码,那就只能源码安装了,下载源码之后
得到的文件夹里readme有这样一段话
You need to compile Xdebug separately from the rest of PHP. Note, however,
that you need access to the scripts "phpize" and "php-config". If your
system does not have "phpize" and "php-config", you will need to compile
and install PHP from a source tarball first, as these script are
by-products of the PHP compilation and installation processes. It is
important that the source version matches the installed version as there
are slight, but important, differences between PHP versions.
Once you have access to "phpize" and "php-config", do the following:
看来还必须源码安装php,从而得到phpize(扩展php模块用的工具)
下载php源码,解压缩.configure 的时候出现
./configure --prefix=/usr/local/php --with-apxs=/usr/local/apache --with-mysql
configure: error: xml2-config not found. Please check your libxml2 installation.
yum search xml2 并安装之,之后make&&make install
安装完毕进入xdebug目录执行folder/phpize
出现
Cannot find autoconf. Please check your autoconf installation and the
$PHP_AUTOCONF environment variable. Then, rerun this script.
yum search autoconf
yum install之
之后在xdebug目录下phpize
之后 ./configure --enable-xdebug
make&& make install
安装完毕
在/usr/local/lib64/extensions/no-debug-non-zts-20090626下出现了一个xdebug.so
这个就是我想要的
之后,php就支持了xdebug
配置完成之后,往往会出现netbeans无法连接到xdebug的情况,我的php.ini 关于xdebug的配置如下
zend_extension ="/usr/local/lib64/extensions/no-debug-non-zts-20090626/xdebug.so"
[Xdebug]
xdebug.profiler_enable=off
xdebug.profiler_enable_trigger = off
xdebug.trace_output_dir="/usr/local/php5/xdebug/"
xdebug.profiler_output_dir="/usr/local/php5/xdebug/"
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000
这里注意端口,是9000,要和netbeans的php设置中的调试界面中的端口设置要一样,另外phpinfo()之后,可以看到有个IDE Key,这个和netbeans中php中调试中的会话ID一致,我的netbeans连接不上xdebug是因为我的端口号设错了,一般来说,完成这些步骤,应该就可以在netbeans中调试PHP了。
- centos 下安装xdebug以便netbeans调试PHP
- netbeans下 xdebug调试php
- netbeans+xdebug调试php
- netbeans安装xdebug调试
- NetBeans+PHP+XDebug调试程序
- NetBeans+Xdebug调试php代码
- netbeans-xdebug 断点调试php
- 在Window下安装xdebug调试php
- window下安装php调试工具xdebug
- 使用NetBeans + Xdebug调试PHP程序[总结]
- 使用NetBeans + Xdebug调试PHP程序
- 使用NetBeans + Xdebug调试PHP程序
- 使用NetBeans + Xdebug调试PHP程序
- 使用NetBeans + Xdebug调试PHP程序
- 使用NetBeans + Xdebug调试PHP程序[总结]
- NetBeans配置Xdebug 远程调试PHP
- NetBeans配置Xdebug 远程调试PHP
- netbeans xdebug 调试PHP discuz详解
- [6] 算法之路 - 双向冒泡排序之Shaker
- HDU 4967 Handling the Past 线段树 调用顺序
- eclipse关联到源码
- android 流量转发服务器压缩功能实现
- [AppArmor-GUI]五、项目阶段性汇报
- centos 下安装xdebug以便netbeans调试PHP
- 智慧家庭
- mini2440 简单touch screen驱动程序
- class-new()函数, static or automatic(systemverilog)
- sed命令详解
- matlab实现dijkstra、floyd、kruskal
- Combinations
- linux grep命令详解
- java专题——B+树,B-树