# Contributor: Andy Postnikov # Contributor: Valery Kartel # Contributor: Fabio Ribeiro # Maintainer: Andy Postnikov pkgname=php7-pecl-xdebug _pkgname=xdebug pkgver=2.9.0 pkgrel=0 pkgdesc="PHP extension that provides functions for function traces and profiling - PECL" url="https://pecl.php.net/package/xdebug" arch="all" license="PHP-3.0" depends="php7-common" makedepends="php7-dev autoconf re2c" source="$pkgname-$pkgver.tgz::https://pecl.php.net/get/$_pkgname-$pkgver.tgz" builddir="$srcdir/$_pkgname-$pkgver" provides="php7-xdebug=$pkgver-r$pkgrel" # for backward compatibility replaces="php7-xdebug" # for backward compatibility build() { phpize7 ./configure --prefix=/usr --with-php-config=php-config7 make } check() { # PECL package has no test suite. php7 -z "$builddir"/modules/xdebug.so -r "in_array('Xdebug', get_loaded_extensions(true)) ? exit(0) : exit(1);" } package() { local confdir="$pkgdir/etc/php7/conf.d" make INSTALL_ROOT="$pkgdir" install install -D -m644 contrib/tracefile-analyser.php "$pkgdir"/usr/share/php7/xdebug/tracefile-analyser.php mkdir -p "$confdir" cat > "$confdir"/$_pkgname.ini <<-EOF ; Uncomment to enable this extension. ;zend_extension=$_pkgname.so EOF } sha512sums="51f87f55ee5a654c587344d1442b0e6cb74a8bfb138d3ba793a17580851595c97e1d961ce25a473e461ac61d1c8a1634412e6f4e3975116dc0ffc52aa3355d0e php7-pecl-xdebug-2.9.0.tgz"