mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-08-06 05:47:13 +02:00
testing/tvheadend: new aport
This commit is contained in:
parent
246c4ebdca
commit
4d635451b8
45
testing/tvheadend/APKBUILD
Normal file
45
testing/tvheadend/APKBUILD
Normal file
@ -0,0 +1,45 @@
|
||||
# Contributor: Francesco Colista <francesco.colista@gmail.com>
|
||||
# Maintainer: Francesco Colista <francesco.colista@gmail.com>
|
||||
pkgname=tvheadend-git
|
||||
_pkgname=andoma-tvheadend-fdc743f
|
||||
pkgver=2.13
|
||||
pkgrel=0
|
||||
pkgdesc="TV Streaming server for linux"
|
||||
url="http://www.lonelycoder.com/hts/tvheadend_overview.html"
|
||||
arch="all"
|
||||
license="GPL3"
|
||||
depends=""
|
||||
depends_dev="openssl-dev avahi-dev wget bash findutils"
|
||||
makedepends="$depends_dev"
|
||||
install="$pkgname.pre-install $pkgname.post-deinstall"
|
||||
subpackages=""
|
||||
source="saveas-https://github.com/andoma/tvheadend/tarball/master/$pkgname-$pkgver.tar.gz
|
||||
tvheadend-git.initd
|
||||
tvheadend-git.confd
|
||||
"
|
||||
_builddir="$srcdir"/$_pkgname
|
||||
prepare() {
|
||||
local i
|
||||
cd "$_builddir"
|
||||
for i in $source; do
|
||||
case $i in
|
||||
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
|
||||
esac
|
||||
done
|
||||
}
|
||||
build() {
|
||||
cd "$_builddir"
|
||||
./configure --prefix=/usr --release
|
||||
make || return 1
|
||||
}
|
||||
package() {
|
||||
cd "$_builddir"
|
||||
sed -i 's/\-T//g' support/posix.mk
|
||||
make DESTDIR="$pkgdir" install || return 1
|
||||
install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname || return 1
|
||||
install -m755 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname || return 1
|
||||
}
|
||||
|
||||
md5sums="97c51df1daca8db241dee8b9c55d0aad tvheadend-git-2.13.tar.gz
|
||||
4d6324b1b87890faf846ad95c2f3483c tvheadend-git.initd
|
||||
74749f3527418ddfd5671d5d5ad4dca4 tvheadend-git.confd"
|
2
testing/tvheadend/tvheadend-git.confd
Normal file
2
testing/tvheadend/tvheadend-git.confd
Normal file
@ -0,0 +1,2 @@
|
||||
TVHBIN="/usr/bin/tvheadend"
|
||||
TVHUSER="tvheadend"
|
18
testing/tvheadend/tvheadend-git.initd
Normal file
18
testing/tvheadend/tvheadend-git.initd
Normal file
@ -0,0 +1,18 @@
|
||||
#!/sbin/runscript
|
||||
depend() {
|
||||
need net
|
||||
}
|
||||
|
||||
start() {
|
||||
ebegin "Starting tvheadend"
|
||||
start-stop-daemon --start \
|
||||
--user ${TVHUSER} \
|
||||
--exec ${TVHBIN} -- -C -f
|
||||
eend $?
|
||||
}
|
||||
|
||||
stop() {
|
||||
ebegin "Stopping tvheadend"
|
||||
start-stop-daemon --stop --quiet --name tvheadend --signal 2
|
||||
eend $?
|
||||
}
|
4
testing/tvheadend/tvheadend-git.post-deinstall
Normal file
4
testing/tvheadend/tvheadend-git.post-deinstall
Normal file
@ -0,0 +1,4 @@
|
||||
#!/bin/sh
|
||||
|
||||
deluser hts 2>/dev/null
|
||||
exit 0
|
5
testing/tvheadend/tvheadend-git.pre-install
Normal file
5
testing/tvheadend/tvheadend-git.pre-install
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
groupadd tvheadend 2>/dev/null
|
||||
adduser -H -h /home/tvheadend -g tvheadend -D -s /bin/false tvheadend 2>/dev/null
|
||||
gpasswd -a tvheadend video 2>/dev/null
|
||||
exit 0
|
Loading…
Reference in New Issue
Block a user