void-packages/srcpkgs/coturn/template

43 lines
1.1 KiB
Bash

# Template file for 'coturn'
pkgname=coturn
version=4.5.1.0
revision=1
build_style=gnu-configure
conf_files="/etc/turnserver.conf"
makedepends="libressl-devel libevent-devel hiredis-devel sqlite-devel
postgresql-libs-devel libmariadbclient-devel"
short_desc="Server Implementation of TURN and STUN"
maintainer="Toyam Cox <Vaelatern@voidlinux.org>"
license="BSD-3-Clause"
homepage="https://github.com/coturn/coturn"
distfiles="https://github.com/coturn/coturn/archive/${version}.tar.gz"
checksum=9cf6b19ef37104801c412963bc7a6256d43e1016f527aef240a6a872e7c2d227
pre_build() {
# configure script does not like /usr when cross-building
if [ "$CROSS_BUILD" ]; then
LOCALSTATEDIR=/var ./configure --prefix=/tmp --confdir=/etc
sed -i 's:\${MANPREFIX}:/tmp/share:' Makefile
fi
}
system_accounts="_coturn"
post_install() {
if [ "$CROSS_BUILD" ]; then
mv ${DESTDIR}/tmp ${DESTDIR}/usr
fi
vlicense LICENSE
vsv coturnserver
vsconf examples/etc/turnserver.conf
}
coturn-devel_package() {
short_desc="${short_desc} - development files"
depends="${sourcepkg}>=${version}_${revision}"
pkg_install() {
vmove usr/lib/*.a
vmove usr/include
}
}