summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorThore Boedecker2017-05-09 20:54:50 +0200
committerThore Boedecker2017-05-09 20:54:50 +0200
commit9772cfc1af315ba608440fa3582ac7ab5adf4dee (patch)
treefbd37cb518c84cd8f7d71ab84af051babcf0aa0d /PKGBUILD
parent289a45b48ce3d581da3a80b9983949f5573aa5e1 (diff)
downloadaur-9772cfc1af315ba608440fa3582ac7ab5adf4dee.tar.gz
improve pkgbuild quality, add check()
Signed-off-by: Thore Boedecker <me@foxxx0.de>
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD36
1 files changed, 22 insertions, 14 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 6c09d179ece..0404b0074a8 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,9 +2,8 @@
pkgname=php56-geoip
_pkgbase="${pkgname#php56-}"
-_phpbase="${pkgname/-geoip}"
pkgver=1.1.0
-pkgrel=3
+pkgrel=4
pkgdesc="GeoIP module for php56"
arch=('i686' 'x86_64')
url="https://pecl.php.net/package/geoip"
@@ -12,24 +11,33 @@ license=('PHP')
provides=("php-geoip=${pkgver}-${pkgrel}")
depends=('php56>=5.6.17-3' 'geoip')
backup=('etc/php56/conf.d/geoip.ini')
-install=php56-geoip.install
source=("https://pecl.php.net/get/geoip-${pkgver}.tgz")
-md5sums=('1a779f7b3dd275e497846ce302b3776b')
+sha256sums=('82c6deb7264d2ff7c4d6c45a7d27cff7ab097be965795e317e04a9c5b7be98b9')
build() {
- cd "${srcdir}/${_pkgbase}-${pkgver}"
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
- phpize56
- ./configure --prefix=/usr
- make
+ phpize56
+ # ./configure --prefix=/usr
+ ./configure \
+ --config-cache \
+ --sysconfdir=/etc/php56 \
+ --with-php-config=/usr/bin/php-config56 \
+ --localstatedir=/var
+ make
+}
+
+check() {
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ # disable prompt to send test report
+ export NO_INTERACTION=1
+ make test
}
package() {
- cd "${srcdir}/${_pkgbase}-${pkgver}"
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
- make INSTALL_ROOT="$pkgdir" install
- echo ';extension=geoip.so' >geoip.ini
- install -Dm644 geoip.ini "$pkgdir/etc/php56/conf.d/geoip.ini"
+ make INSTALL_ROOT="$pkgdir" install
+ echo ';extension=geoip.so' >geoip.ini
+ install -Dm644 geoip.ini "$pkgdir/etc/php56/conf.d/geoip.ini"
}
-
-# vim:set ts=2 sw=2 et: