Robert Förster
e87c0b9b65
NB: TSDNS support in the ebuild might go away in the future in favor of SRV records as they do not require some additional services
61 lines
1.9 KiB
Bash
61 lines
1.9 KiB
Bash
# Copyright 1999-2012 Gentoo Foundation
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
# $Header: /var/cvsroot/gentoo-x86/media-sound/teamspeak-server-bin/teamspeak-server-bin-3.0.5-r2.ebuild,v 1.2 2012/06/09 23:22:53 zmedico Exp $
|
|
|
|
EAPI=4
|
|
|
|
inherit eutils systemd user
|
|
|
|
DESCRIPTION="TeamSpeak Server - Voice Communication Software"
|
|
HOMEPAGE="http://teamspeak.com/"
|
|
LICENSE="teamspeak3"
|
|
SLOT="0"
|
|
IUSE=""
|
|
KEYWORDS="~amd64 ~x86"
|
|
RESTRICT="strip"
|
|
|
|
SRC_URI="
|
|
amd64? ( http://ftp.4players.de/pub/hosted/ts3/releases/${PV}/teamspeak3-server_linux-amd64-${PV}.tar.gz )
|
|
x86? ( http://ftp.4players.de/pub/hosted/ts3/releases/${PV}/teamspeak3-server_linux-x86-${PV}.tar.gz )
|
|
"
|
|
|
|
S="${WORKDIR}/teamspeak3-server_linux-${ARCH}"
|
|
|
|
DEPEND=""
|
|
RDEPEND="${DEPEND}"
|
|
|
|
pkg_setup() {
|
|
enewuser teamspeak3
|
|
}
|
|
|
|
src_install() {
|
|
local dest="${D}/opt/teamspeak3-server"
|
|
|
|
mkdir -p "${dest}"
|
|
cp -R "${WORKDIR}/teamspeak3-server_linux-"*/* "${dest}/" || die
|
|
|
|
mv "${dest}/ts3server_linux_"* "${dest}/ts3server-bin" || die
|
|
mv "${dest}/tsdns/tsdnsserver_linux_"* "${dest}/tsdns/tsdnsserver" || die
|
|
|
|
exeinto /usr/sbin || die
|
|
doexe "${FILESDIR}/ts3server" || die
|
|
|
|
# runtime FS layout ...
|
|
insinto /etc/teamspeak3-server
|
|
doins "${FILESDIR}/server.conf"
|
|
newins "${dest}/tsdns/tsdns_settings.ini.sample" tsdns_settings.ini
|
|
dosym "${D}"/etc/teamspeak3-server/tsdns_settings.ini /opt/teamspeak3-server/tsdns/tsdns_settings.ini
|
|
newinitd "${FILESDIR}/teamspeak3-server.rc" teamspeak3-server
|
|
newinitd "${FILESDIR}/teamspeak3-tsdns-server.rc" teamspeak3-tsdns-server
|
|
|
|
keepdir /{etc,var/{lib,log,run}}/teamspeak3-server
|
|
fowners teamspeak3 /{etc,var/{lib,log,run}}/teamspeak3-server
|
|
fperms 700 /{etc,var/{lib,log,run}}/teamspeak3-server
|
|
|
|
fowners teamspeak3 /opt/teamspeak3-server
|
|
fperms 755 /opt/teamspeak3-server
|
|
|
|
systemd_dounit "${FILESDIR}/systemd/teamspeak3.service"
|
|
systemd_dotmpfilesd "${FILESDIR}/systemd/teamspeak3.conf"
|
|
}
|