aboutsummaryrefslogtreecommitdiffstats
path: root/testing/mpdcron/APKBUILD
blob: 5d1654d7e037d34a45bbab8efc435156bfa6d3c8 (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
# Contributor: dai9ah <dai9ah@protonmail.com>
# Maintainer: dai9ah <dai9ah@protonmail.com>
pkgname=mpdcron
pkgver=0.3
pkgrel=0
pkgdesc="Cron-like daemon for mpd"
url="https://github.com/alip/mpdcron"
arch="all"
license="GPL-2.0-only"
makedepends="autoconf automake curl-dev glib-dev libdaemon-dev libmpdclient-dev
	libnotify-dev libtool sqlite-dev
	"
subpackages="$pkgname-doc
	$pkgname-dev
	$pkgname-zsh-completion:zshcomp:noarch
	"
source="$pkgname-$pkgver.tar.gz::https://github.com/alip/$pkgname/archive/v$pkgver.tar.gz"
builddir="$srcdir/$pkgname-$pkgver"

build() {
	cd "$builddir"
	./autogen.sh
	./configure \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--enable-gmodule \
		--with-standard-modules=all
	make
}

check() {
	cd "$builddir"/src
	./mpdcron --help > /dev/null
}

package() {
	make DESTDIR="$pkgdir" -C "$builddir" install
}

zshcomp() {
	pkgdesc="Zsh completions for $pkgname"
	install_if="$pkgname=$pkgver-r$pkgrel zsh"

	mkdir -p "$subpkgdir"/usr/share/zsh/site-functions
	install -Dm644 "$builddir"/zsh-completion/_* \
		"$subpkgdir"/usr/share/zsh/site-functions/
}

sha512sums="19c55d9edfeda7ecd317c449d195f90c3bda04f0d7a26cc6395b437f7d501e3ea8a00820367807e61c073ed6aa38bd69fc4948de8061cbbd20f7f393204d11e5  mpdcron-0.3.tar.gz"