1 # Maintainer: David Spicer <azleifel at googlemail dot com>
2 # Contributor: Mika Hynnä <mikaDOThynnaATwippiesDOTcom>
7 pkgdesc="A web based interface to VDR"
9 url="http://andreas.vdr-developer.org/"
11 depends=('vdr' 'perl' 'perl-locale-gettext' 'perl-authen-sasl' 'perl-digest-hmac'
13 optdepends=('perl-io-socket-inet6: IPv6 support'
14 'perl-io-socket-ssl: SSL Support')
15 backup=('etc/vdradmin/vdradmind.conf')
16 install=vdradmin-am.install
17 source=(http://andreas.vdr-developer.org/vdradmin-am/download/$pkgname-$pkgver.tar.bz2
21 md5sums=('95809a04838121e4ed81f14fd6448886'
22 'f9002d75ed1b0fc71c6fe9210c9075c4'
23 '8fc1e4761dff131d1d638018dc976511'
24 '9801ebdd7d609f6f3aa3828783d89d46')
27 cd "${srcdir}"/$pkgname-$pkgver
29 # Patch removes checks for IPv6 support and SSL support, and fixes installation
30 # directories and install process, removing attempted vdradmin restart
31 patch -Np0 -i "${srcdir}"/install.sh.patch
33 # Assumed VDR directory environment (VDRDIR/Make.config):
34 # VIDEODIR = /var/spool/video
38 DESTDIR="${pkgdir}" ./make.sh install
40 # Create directories vdradmind expects to exist
41 install -d "${pkgdir}"/var/cache/vdradmin
42 install -d "${pkgdir}"/var/log/vdradmin
45 install -D -m755 "${srcdir}"/rc-vdradmind "${pkgdir}"/etc/rc.d/vdradmind
47 # Install /var/run conf file
48 install -D -m644 "${srcdir}"/run-vdradmind.conf "${pkgdir}"/usr/lib/tmpfiles.d/vdradmind.conf
50 # Create base configuration
51 echo -e "\n\n\n\nvdradmin\nvdradmin\n/var/spool/video\n/etc/vdr\n" | ./vdradmind --config
52 sed -i "s/ST_STREAMDEV_HOST = /ST_STREAMDEV_HOST = 127.0.0.1/" vdradmind.conf
53 install -D -m644 vdradmind.conf "${pkgdir}"/etc/vdradmin/vdradmind.conf