# Contributor: Andy Postnikov # Contributor: Valery Kartel # Contributor: Fabio Ribeiro # Maintainer: Andy Postnikov pkgname=php82-pecl-xdebug _extname=xdebug pkgver=3.2.0 pkgrel=0 pkgdesc="PHP 8.2 extension that provides functions for function traces and profiling - PECL" url="https://pecl.php.net/package/xdebug" arch="all" license="PHP-3.0" depends="php82-common" makedepends="php82-dev linux-headers" source="php-pecl-$_extname-$pkgver.tgz::https://pecl.php.net/get/$_extname-$pkgver.tgz" builddir="$srcdir/$_extname-$pkgver" provides="php82-xdebug=$pkgver-r$pkgrel" # for backward compatibility replaces="php82-xdebug" # for backward compatibility build() { phpize82 ./configure --prefix=/usr --with-php-config=php-config82 make } check() { # PECL package has no test suite. php82 -d zend_extension="$builddir"/modules/xdebug.so -r 'xdebug_info();' } package() { make INSTALL_ROOT="$pkgdir" install local _confdir="$pkgdir"/etc/php82/conf.d mkdir -p $_confdir # should go after opcache cat > $_confdir/50_$_extname.ini <<-EOF ; Uncomment and configure mode https://xdebug.org/docs/all_settings#xdebug.mode ;zend_extension=$_extname.so ;xdebug.mode=off EOF install -D -m644 -t "$pkgdir"/usr/share/php82/xdebug/ contrib/tracefile-analyser.php install -D -m644 -t "$pkgdir"/usr/share/vim/vimfiles/syntax/ contrib/xt.vim } sha512sums=" 357acd17e1b74f39278d9fad6d1038c283d3b7a736c32c7188836815aa0f07eadd437cf4e06d8f03a724a13be28e7d72e7c3a6e9adda1335309ec12495d81392 php-pecl-xdebug-3.2.0.tgz "