36 lines
945 B
Bash
36 lines
945 B
Bash
# Template file for 'redis'
|
|
pkgname=redis
|
|
version=4.0.0
|
|
revision=1
|
|
makedepends="jemalloc-devel"
|
|
homepage="http://redis.io"
|
|
distfiles="http://download.redis.io/releases/${pkgname}-${version}.tar.gz"
|
|
short_desc="Advanced key-value store"
|
|
maintainer="Enno Boland <gottox@voidlinux.eu>"
|
|
license="BSD"
|
|
checksum=d539ae309295721d5c3ed7298939645b6f86ab5d25fdf2a0352ab575c159df2d
|
|
|
|
system_accounts="redis"
|
|
redis_homedir="/var/lib/redis"
|
|
conf_files="/etc/redis/redis.conf"
|
|
|
|
do_configure() {
|
|
sed -i \
|
|
-e "s|^# bind 127.0.0.1|bind 127.0.0.1|" \
|
|
-e "s|^dir .*|dir ${redis_homedir}|" \
|
|
-e "s|^pidfile .*|pidfile /run/redis/redis.pid|" redis.conf
|
|
}
|
|
do_build() {
|
|
case "$XBPS_TARGET_MACHINE" in
|
|
*-musl) _malloc="none";;
|
|
*) _malloc="jemalloc";;
|
|
esac
|
|
make CC=$CC CFLAGS="$CFLAGS" MALLOC=${_malloc} ${makejobs}
|
|
}
|
|
do_install() {
|
|
make INSTALL_BIN=${DESTDIR}/usr/bin PREFIX=/usr install
|
|
vlicense COPYING
|
|
|
|
vinstall redis.conf 644 etc/redis
|
|
vsv redis
|
|
}
|