aboutsummaryrefslogtreecommitdiffstats
path: root/community/php7-event
diff options
context:
space:
mode:
authorAndy Postnikov <apostnikov@gmail.com>2018-08-15 16:20:43 +0300
committerAndy Postnikov <apostnikov@gmail.com>2018-08-15 17:07:14 +0300
commit4f31868e9a10836e76759f32a0074b6d6e6ebfcf (patch)
tree68e3d1d706df4e2d6d53b47b9b702f776259b5ba /community/php7-event
parentf0d3120de37a7197f4793bb3bd86108f03aebc62 (diff)
downloadaports-4f31868e9a10836e76759f32a0074b6d6e6ebfcf.tar.bz2
aports-4f31868e9a10836e76759f32a0074b6d6e6ebfcf.tar.xz
testing/php7-event: move to community
Diffstat (limited to 'community/php7-event')
-rw-r--r--community/php7-event/APKBUILD40
1 files changed, 40 insertions, 0 deletions
diff --git a/community/php7-event/APKBUILD b/community/php7-event/APKBUILD
new file mode 100644
index 0000000000..fb126cdec1
--- /dev/null
+++ b/community/php7-event/APKBUILD
@@ -0,0 +1,40 @@
+# Contributor: Andy Postnikov <apostnikov@gmail.com>
+# Maintainer: Andy Postnikov <apostnikov@gmail.com>
+pkgname=php7-event
+_pkgname=event
+pkgver=2.4.1
+pkgrel=0
+pkgdesc="PHP extension that provides interface to libevent library"
+url="https://pecl.php.net/package/event"
+arch="all"
+license="PHP-3.01"
+depends="php7 php7-sockets"
+makedepends="php7-dev autoconf libevent-dev libressl-dev pkgconf"
+source="$pkgname-$pkgver.tgz::https://pecl.php.net/get/$_pkgname-$pkgver.tgz"
+builddir="$srcdir/$_pkgname-$pkgver"
+
+build() {
+ cd "$builddir"
+
+ phpize7
+ ./configure --prefix=/usr --with-php-config=php-config7
+ make
+}
+
+check() {
+ cd "$builddir"
+ # Tests require sockets extension which is not bundled
+ sed -i 's#PHP_TEST_SHARED_EXTENSIONS = `#PHP_TEST_SHARED_EXTENSIONS = -d extension=/usr/lib/php7/modules/sockets.so `#' Makefile
+ make NO_INTERACTION=1 REPORT_EXIT_STATUS=1 test
+}
+
+package() {
+ cd "$builddir"
+
+ make INSTALL_ROOT="$pkgdir" install
+
+ install -d "$pkgdir"/etc/php7/conf.d
+ echo "extension=$_pkgname.so" > "$pkgdir"/etc/php7/conf.d/$_pkgname.ini
+}
+
+sha512sums="d115fa12dfefe164532b39b6a79f01c2c00e2718967c3d675584a0dd193b155cdc74a632f6327239e201720fbabd440b9434bde5de4a9e30373595636dafad94 php7-event-2.4.1.tgz"