aboutsummaryrefslogtreecommitdiffstats
path: root/community/libhdhomerun/APKBUILD
blob: 4684c9c97741c591257bbb67838f06019a89e343 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# Contributor: Hasse Hagen Johansen <hasse-docker@hagenjohansen.dk>
# Maintainer: Hasse Hagen Johansen <hasse-docker@hagenjohansen.dk>
pkgname=libhdhomerun
pkgver=20150826
pkgrel=1
pkgdesc="Library for Silicon Dust HD HomeRun"
url="http://www.silicondust.com/support/downloads/linux/"
arch="all"
license="LGPL2+"
depends="$pkgname-libs"
depends_dev="$pkgname"
makedepends="$depends_dev"
install=""
subpackages="$pkgname-dev $pkgname-libs"
source="http://download.silicondust.com/hdhomerun/${pkgname}_${pkgver}.tgz"

_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"
	make || return 1
}

package() {
	cd "$_builddir"
	install -Dm755 hdhomerun_config \
		"$pkgdir"/usr/bin/hdhomerun_config || return 1
	for i in *.h; do
		install -Dm644 $i \
			"$pkgdir"/usr/include/libhdhomerun/$i || return 1
	done
}

# libhdhomerun does not provide versioned libs so we cannot
# use abuilds libs split function, so we make our own.
libs() {
	pkgdesc="$pkgname (libraries)"
	install -Dm755 "$_builddir"/libhdhomerun.so \
		"$subpkgdir"/usr/lib/libhdhomerun.so || return 1
}

md5sums="05f9a9e1fc8f6ec004b399034775cab0  libhdhomerun_20150826.tgz"
sha256sums="907dfbd1eb82aebd8b09e7c00c21a02433e6baaacf4a4f99aa2511b1d5244baf  libhdhomerun_20150826.tgz"
sha512sums="9b401c1649dc8c32ea9019b732631f9213cb66c43771aa148fa318202fc11739c005c474be6a77a6a7807818b5179f77debb5b2d2411d865cc87bb3d7ab629a6  libhdhomerun_20150826.tgz"