aboutsummaryrefslogtreecommitdiffstats
path: root/testing/php7-pecl-solr/APKBUILD
blob: 5d666aa68480874d503bb5480cc761a21d751057 (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
# Contributor: Fabio Ribeiro <fabiorphp@gmail.com>
# Maintainer: Fabio Ribeiro <fabiorphp@gmail.com>
pkgname=php7-pecl-solr
_pkgreal=solr
pkgver=2.4.0
_pkgver=${pkgver}
pkgrel=5
pkgdesc="Apache SOLR extension for PHP"
url="https://pecl.php.net/package/$_pkgreal"
arch="all"
license="PHP"
depends="php7-json"
makedepends="php7-dev curl-dev libxml2-dev autoconf pcre-dev"
source="https://pecl.php.net/get/$_pkgreal-$_pkgver.tgz
	fix-zend_acc_public.patch
	"
builddir="$srcdir"/$_pkgreal-$_pkgver
provides="php7-solr=$pkgver-r$pkgrel" # for backward compatibility
replaces="php7-solr" # for backward compatibility

build() {
	cd "$builddir"
	phpize7
	./configure --prefix=/usr --with-php-config=php-config7
	make
}

check() {
	# Require Solr installed
	php7 -d extension="$builddir"/modules/$_pkgreal.so --ri $_pkgreal
}

package() {
	cd "$builddir"
	make INSTALL_ROOT="$pkgdir"/ install
	install -d "$pkgdir"/etc/php7/conf.d
	echo "extension=$_pkgreal.so" > "$pkgdir"/etc/php7/conf.d/40_$_pkgreal.ini
}

sha512sums="05b6e252fadf55a7104bc6963e522684dad80540315e89729f4c589698ee68ff71f0e536b0e38ee4ae10b01cb04115ca12ced2897c3145d46fc54ab719de3590  solr-2.4.0.tgz
44f171c887e3b3a28d1294fe443d16aa0cef3ad25e92764ea6cb03bb5da26fb520bcec487f1f3cb188957a19221898d424967d4f6c67efc64def64c921a638d6  fix-zend_acc_public.patch"