Xdebug — Step Debugger and Debugging Aid for PHP
Clone or download
Latest commit 82f0bb0 Oct 19, 2018
Permalink
Failed to load latest commit information.
.appveyor Fixed issue #938: Improve support for debugging forked PHP scripts Mar 28, 2018
.travis.scripts Fixed issue #1511: Detect and use compiler flags through new configur… Jan 8, 2018
contrib Remove unused Git attributes ident Jul 23, 2018
debugclient Change http://xdebug.org to https://xdebug.org everywhere Sep 20, 2018
docs typo fixes - https://github.com/vlajos/misspell_fixer Jan 6, 2015
tests Fixed issue #1571: File/line information is not shown for closures in… Oct 18, 2018
.appveyor.yml Enable 7.3 for AppVeyor Sep 20, 2018
.gitignore Add .gitignore from tests to root directory Jul 23, 2018
.travis.yml Update Travis for 7.3/nightly, which is now 7.4 Sep 20, 2018
CONTRIBUTING.rst Tidy up some language. May 25, 2015
CREDITS - Update CREDITS Apr 6, 2003
LICENSE Change http://xdebug.org to https://xdebug.org everywhere Sep 20, 2018
Makefile.frag Change http://xdebug.org to https://xdebug.org everywhere Sep 20, 2018
README.rst Change http://xdebug.org to https://xdebug.org everywhere Sep 20, 2018
compile.bat - Windows build fixes Jan 13, 2004
config.m4 Fixed issue #1511: Detect and use compiler flags through new configur… Jan 8, 2018
config.w32 Header maintenance (and welcome to 2018) Jan 1, 2018
package.xml Added 2.6.1 changelog Sep 20, 2018
php_xdebug.h We're at beta2-dev now Oct 18, 2018
rebuild-32bit.sh Fixed issue #1212: Segfault with code coverage dead code analysis and… Nov 29, 2015
rebuild.sh Fixed issue #1511: Detect and use compiler flags through new configur… Jan 8, 2018
template.rc We're at beta2-dev now Oct 18, 2018
test.sh Allow test files to be passed as the TESTS env var. Apr 8, 2012
usefulstuff.c Merge branch 'xdebug_2_6' Mar 30, 2018
usefulstuff.h Merge branch 'xdebug_2_6' Mar 30, 2018
xdebug.c Fixed storage type of xdebug.cli_color setting Sep 20, 2018
xdebug.ini Change http://xdebug.org to https://xdebug.org everywhere Sep 20, 2018
xdebug_branch_info.c Don't use static (empty) strings as placeholder, but NULL instead Jan 8, 2018
xdebug_branch_info.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_code_coverage.c Fixed issue #1571: File/line information is not shown for closures in… Oct 18, 2018
xdebug_code_coverage.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_com.c Tweak resetting debug connections a little Mar 28, 2018
xdebug_com.h Tweak resetting debug connections a little Mar 28, 2018
xdebug_compat.c New PHP 7.3 cookie API Sep 20, 2018
xdebug_compat.h Fixed issue #1578: Compile error due to redefinition of "zif_handler"… Sep 21, 2018
xdebug_filter.c Fixed issue #1525: Namespace filter does equality match instead of pr… Feb 9, 2018
xdebug_filter.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_gc_stats.c Fix build for PHP 7.3 Sep 20, 2018
xdebug_gc_stats.h Fix duplicate symbol xdebug_old_gc_collect_cycles Jan 2, 2018
xdebug_handler_dbgp.c Change http://xdebug.org to https://xdebug.org everywhere Sep 20, 2018
xdebug_handler_dbgp.h Fixed issue #1516: Can't fetch variables or object properties which h… Jan 18, 2018
xdebug_handlers.c Get rid of outdated debug handler revisions Jan 8, 2018
xdebug_handlers.h Fixed issue #938: Improve support for debugging forked PHP scripts Mar 28, 2018
xdebug_hash.c Remove default sorting method in xdebug_hash_apply_with_argument Jan 13, 2018
xdebug_hash.h Allow different sorting mechnisms for values stored within hashes Jan 13, 2018
xdebug_llist.c Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_llist.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_mm.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_monitor.c Allow different sorting mechnisms for values stored within hashes Jan 13, 2018
xdebug_monitor.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_private.c Fixed issue #1514: Variable names with a NULL char are cut off at NUL… Jan 13, 2018
xdebug_private.h Fixed issue #938: Improve support for debugging forked PHP scripts Mar 28, 2018
xdebug_profiler.c const/char const mishaps Jan 8, 2018
xdebug_profiler.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_set.c Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_set.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_stack.c Fixed issue #1571: File/line information is not shown for closures in… Oct 18, 2018
xdebug_stack.h Fixed issue #1571: File/line information is not shown for closures in… Oct 18, 2018
xdebug_str.c Add new string functions Jan 13, 2018
xdebug_str.h Fixed bug #1515: Object property names with a NULL char are cut off a… Jan 16, 2018
xdebug_superglobals.c Fixed bug #1515: Object property names with a NULL char are cut off a… Jan 16, 2018
xdebug_superglobals.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_trace_computerized.c Fix build for PHP 7.3 Sep 20, 2018
xdebug_trace_computerized.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_trace_html.c Fixed issue #1543: Various memory leaks due to changes in (internal) … Mar 30, 2018
xdebug_trace_html.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_trace_textual.c Fix build for PHP 7.3 Sep 20, 2018
xdebug_trace_textual.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_tracing.c Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_tracing.h Header maintenance (and welcome to 2018) Jan 1, 2018
xdebug_var.c Use a PHP version dependent conditional function for hash recursion p… Sep 20, 2018
xdebug_var.h zend_get_zval_ptr needs the *right* opline in PHP 7.3 Sep 20, 2018
xdebug_xml.c const/char const mishaps Jan 8, 2018
xdebug_xml.h const/char const mishaps Jan 8, 2018

README.rst

Xdebug

https://travis-ci.org/xdebug/xdebug.svg?branch=master

https://ci.appveyor.com/api/projects/status/glp9xfsmt1p25nkn?svg=true

These are instructions for installing Xdebug from a Git checkout. Please refer to https://xdebug.org/support.php for support.

Introduction

You need to compile Xdebug separately from the rest of PHP. You need to have 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, or install a php-dev package if your distribution provides one. These scripts are by-products of the PHP compilation and installation processes and are needed to compile external extensions. It is important that the source version matches the installed version as there are slight, but important, differences between PHP versions.

Clone

You can clone the Xdebug source directory with:

git clone https://github.com/xdebug/xdebug.git

Then move into this new directory:

cd xdebug

Although it is recommended to run the latest version from the master branch, older versions are available through tags. For example to checkout the 2.5.5 release, you can switch to it with git checkout XDEBUG_2_5_5.

Compile

If PHP is installed in a normal, and uncomplicated way, with default locations and configuration, all you will need to do is to run the following script:

./rebuild.sh

This will run phpize, ./configure, make clean, make and make install.

The long winded way of installation is:

  1. Run phpize: phpize (or /path/to/phpize if phpize is not in your path).

  2. ./configure --enable-xdebug (or: ../configure --enable-xdebug --with-php-config=/path/to/php-config if php-config is not in your path)

  3. Run: make clean

  4. Run: make

  5. Run: make install

  6. Add the following line to php.ini (which you can find by running php --ini, or look at phpinfo() output): zend_extension="xdebug.so".

    Please note, that sometimes the php.ini file is different for the command line and for your web server. Make sure you pick the right one.

  7. Unless you exclusively use the command line with PHP, restart your webserver.

  8. Write a PHP page that calls phpinfo();. Load it in a browser and look for the info on the Xdebug module. If you see it, you have been successful! Alternatively, you can run php -v on the command line to see that Xdebug is loaded:

    $ php -v
    PHP 7.2.0RC6 (cli) (built: Nov 23 2017 10:30:56) ( NTS DEBUG )
    Copyright (c) 1997-2017 The PHP Group
    Zend Engine v3.2.0-dev, Copyright (c) 1998-2017 Zend Technologies
            with Xdebug v2.6.0-dev, Copyright (c) 2002-2017, by Derick Rethans
    

Support

For questions regarding compile issues, please write to the xdebug-general email list which you can find at https://xdebug.org/support.php#list

You can also find support on IRC: freenode/#xdebug. You can do that with your favourite client, or by using their webchat.

If you think that you encountered a bug, please file a detailed bug report at https://bugs.xdebug.org. You are required to create an account, this is so that you can be contacted for additional information and to keep out spam.

Derick Rethans — derick@xdebug.org