aboutsummaryrefslogtreecommitdiffstats
path: root/community/php7-pecl-xdebug/APKBUILD
blob: eef000a0f7ae9e69feedcca51fa0f6ae9ebd9089 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Contributor: Andy Postnikov <apostnikov@gmail.com>
# Contributor: Valery Kartel <valery.kartel@gmail.com>
# Contributor: Fabio Ribeiro <fabiorphp@gmail.com>
# Maintainer: Andy Postnikov <apostnikov@gmail.com>
pkgname=php7-pecl-xdebug
_pkgname=xdebug
pkgver=2.7.1
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"
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() {
	cd "$builddir"

	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"
	cd "$builddir"

	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="f93b0ff14e21f557beb7409604d23862ea622bb0d0bf150a8e2b3aa65acb947e2405a9d0b60b409001ae2290bbd3e73f411fc1f0829e3d78a67e8620bde2e2ae  php7-pecl-xdebug-2.7.1.tgz"