aboutsummaryrefslogtreecommitdiffstats
path: root/community/minidlna/APKBUILD
blob: c9f5a0536a3c8b9d4e9a6f69fc75aa9b674420e0 (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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Francesco Colista <francesco.colista@gmail.com>
pkgname=minidlna
pkgver=1.2.0
pkgrel=0
pkgdesc="A small dlna server"
url="http://sourceforge.net/projects/minidlna/"
arch="all"
license="GPL"
depends=
options=
makedepends="
	bsd-compat-headers
	libvorbis-dev
	libogg-dev
	libid3tag-dev
	libexif-dev
	libjpeg-turbo-dev
	sqlite-dev
	ffmpeg-dev
	flac-dev
	"
install="minidlna.pre-install minidlna.post-upgrade"
subpackages="$pkgname-doc"
pkgusers="$pkgname"
pkggroups="$pkgname"
source="http://downloads.sourceforge.net/project/minidlna/minidlna/$pkgver/minidlna-$pkgver.tar.gz
	$pkgname.initd
	$pkgname.confd
	10-minidlna-nfo.patch"

builddir="$srcdir/$pkgname-$pkgver"

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--with-os-name="Alpine Linux" \
		--with-db-path=/var/lib/minidlna \
		--with-log-path=/var/log/minidlna \
		|| return 1
	make || return 1
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install || return 1
	install -dm750 -o $pkgusers -g $pkggroups \
		"$pkgdir/var/lib/$pkgname" \
		"$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
	install -m644 -D "$pkgname.conf" \
		"$pkgdir"/etc/$pkgname.conf || return 1
	install -Dm644 "$srcdir"/$pkgname-$pkgver/minidlna.conf.5 \
		"$pkgdir"/usr/share/man/man5/minidlna.conf.5 || return 1
	install -Dm644 "$srcdir"/$pkgname-$pkgver/minidlnad.8 \
		"$pkgdir"/usr/share/man/man8/minidlnad.8 || return 1
}

sha512sums="96dfe4d1f98b7797793b83246d9fbf9c09a885ba6c6a5be669c47eb53e8b6201a4c50723a726ffc3bb9bb96f5560a4880cdb86d6f63f3cc7360bc4e059704e4f  minidlna-1.2.0.tar.gz
e16961bb68c004297f1e26422b1d15bd8583ba2e0e36c88902a45573b685993fff88d2d0dae8c624eaeddb0deca614dbc13b8345f34b4c348961c00b05c0df30  minidlna.initd
e209848af0d79069ac989ad61d3be610b4c0c2783a207a50463a25ec3811b04d1da3a2acde54749878bec44e1567874ede827b978d5472c00f6a855663e5cbf8  minidlna.confd
59a97ef0a36d3ae44dd2e182a0b106f84ce5c17e7dc14ee0459b17430b57ddc59a74e8e67fc0a90326fa451a505b97a0b719b438475efac144028dd012b44af1  10-minidlna-nfo.patch"