mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-04-11 12:06:41 +02:00
78 lines
2.2 KiB
Text
78 lines
2.2 KiB
Text
# Automatically generated by apkbuild-cpan, template 4
|
|
# Maintainer: Celeste <cielesti@protonmail.com>
|
|
maintainer="Celeste <cielesti@protonmail.com>"
|
|
pkgname=perl-net-async-redis
|
|
pkgver=6.006
|
|
pkgrel=0
|
|
#_pkgreal is used by apkbuild-cpan to find modules at MetaCpan
|
|
_pkgreal=Net-Async-Redis
|
|
pkgdesc="Redis support for IO::Async"
|
|
url="https://metacpan.org/release/Net-Async-Redis/"
|
|
arch="noarch"
|
|
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
|
|
depends="
|
|
perl perl-cache-lru perl-class-method-modifiers perl-curry
|
|
perl-digest-crc perl-dir-self perl-file-sharedir
|
|
perl-file-sharedir-install perl-full
|
|
perl-future perl-future-asyncawait
|
|
perl-future-queue perl-io-async perl-list-binarysearch-xs
|
|
perl-log-any perl-math-random-secure perl-metrics-any
|
|
perl-object-pad perl-path-tiny perl-ryu
|
|
perl-ryu-async perl-syntax-keyword-dynamically
|
|
perl-syntax-keyword-match perl-syntax-keyword-try
|
|
perl-uri perl-uri-redis perl-yaml-libyaml
|
|
"
|
|
checkdepends="
|
|
perl-sub-identify perl-test-checkdeps perl-test-deep
|
|
perl-test-fatal perl-test-hexstring perl-test-mockmodule
|
|
perl-variable-disposition redis
|
|
"
|
|
subpackages="$pkgname-doc"
|
|
source="https://cpan.metacpan.org/authors/id/T/TE/TEAM/Net-Async-Redis-$pkgver.tar.gz"
|
|
builddir="$srcdir/$_pkgreal-$pkgver"
|
|
|
|
build() {
|
|
export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
|
|
PERL_MM_USE_DEFAULT=1 perl -I. Makefile.PL \
|
|
INSTALLDIRS=vendor \
|
|
NO_PACKLIST=1 \
|
|
NO_PERLLOCAL=1
|
|
make
|
|
}
|
|
|
|
check() {
|
|
export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
|
|
export NET_ASYNC_REDIS_HOST="127.0.0.1"
|
|
|
|
redis-server \
|
|
--dir "$builddir" \
|
|
--loglevel warning \
|
|
--unixsocket "$builddir"/redis.sock &
|
|
local _redispid=$!
|
|
|
|
# make sure socket is available before we start running tests
|
|
local _n=100 # wait up to 10 sec
|
|
while ! [ -e "$builddir"/redis.sock ] && [ $_n -gt 0 ]; do
|
|
sleep 0.1s
|
|
# shellcheck disable=SC3039
|
|
let _n="$_n - 1"
|
|
done
|
|
|
|
make test || (kill $_redispid && false)
|
|
kill $_redispid
|
|
}
|
|
|
|
package() {
|
|
make DESTDIR="$pkgdir" install
|
|
}
|
|
|
|
doc() {
|
|
local file; find "$pkgdir" -name "*.pod" | while read -r file; do
|
|
amove "${file#"$pkgdir"}"
|
|
done
|
|
default_doc
|
|
}
|
|
|
|
sha512sums="
|
|
fb22bc4638224e8451e73bc190d901ae903ed5ac5f9ec3b044291433d15700c993dac943dcffcf25fa5ce75dca579a1cd887f4a225709e416b54c9239e294bd5 Net-Async-Redis-6.006.tar.gz
|
|
"
|