# Contributor: Carlo Landmeter # Maintainer: pkgname=oscam-svn pkgver=7798 pkgrel=0 pkgdesc="An Open Source Conditional Access Module software" url="http://oscam.to" arch="all" license="GPL" depends="" depends_dev="openssl-dev libusb-dev" makedepends="$depends_dev bash cmake" install="$pkgname.pre-install" pkgusers="$pkgname" subpackages="$pkgname-doc" source="http://alpine.nethq.org/distfiles/oscam-svn-$pkgver.tar.gz $pkgname.initd $pkgname.confd" _builddir="$srcdir"/oscam-svn-$pkgver 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" cmake -DCMAKE_INSTALL_PREFIX=/usr \ -DHAVE_DVBAPI=1 \ -DWEBIF=1 \ -WITH_SSL=1 \ "$_builddir" make || return 1 } package() { cd "$_builddir" make DESTDIR="$pkgdir" install || return 1 install -d "$pkgdir"/var/log/$pkgname/cw || return 1 install -d "$pkgdir"/etc/$pkgname || return 1 chown -R oscam "$pkgdir"/var/log/$pkgname || return 1 install -m755 -D "$srcdir"/$pkgname.initd \ "$pkgdir"/etc/init.d/$pkgname || return 1 install -m644 -D "$srcdir"/$pkgname.confd \ "$pkgdir"/etc/conf.d/$pkgname || return 1 rm -f "$pkgdir"/usr/lib/*.la } md5sums="5dab76a401770f411400927732e5e7f6 oscam-svn-7798.tar.gz 56f8a71e018973b6fb8f2efa2873b6cb oscam-svn.initd 8aa89df1cb43726dc05f6df64c55781a oscam-svn.confd"