aboutsummaryrefslogtreecommitdiffstats
path: root/testing/tpm/APKBUILD
blob: e2fb63ffeec71a8ddd8084620440ee95034e610a (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
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Sören Tempel <soeren+alpine@soeren-tempel.net>
pkgname=tpm
pkgver=1.3
pkgrel=0
pkgdesc="A tiny password manager"
url="http://github.com/nmeum/$pkgname"
arch="noarch"
license="GPL3+"
depends="gnupg"
makedepends="perl"
install=""
subpackages="
	$pkgname-doc
	$pkgname-zsh-completion:zshcomp
	$pkgname-bash-completion:bashcomp"
source="$pkgname-$pkgver.tar.gz::https://github.com/nmeum/$pkgname/archive/$pkgver.tar.gz"

_builddir="$srcdir"/$pkgname-$pkgver
build() {
	make -C "$_builddir" || return 1
}

package() {
	make DESTDIR="$pkgdir" PREFIX="/usr" \
		-C "$_builddir" install || return 1
}

bashcomp() {
	depends=""
	pkgdesc="Bash completions for $pkgname"
	install_if="$pkgname=$pkgver-r$pkgrel bash"
	arch="noarch"

	install -Dm644 "$_builddir"/contrib/bash_completion \
		"$subpkgdir"/usr/share/bash-completion/completions/${pkgname} || return 1
}

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

	install -Dm644 "$_builddir"/contrib/zsh_completion \
		"$subpkgdir"/usr/share/zsh/site-functions/_${pkgname} || return 1
}

md5sums="d3e00bbcb55305c264524de329835c37  tpm-1.3.tar.gz"
sha256sums="97b8bf1e53a122fbebc47c0468a1944d53cf78e237f07cfaecd871b67bebed98  tpm-1.3.tar.gz"
sha512sums="92b373ade177bdbefc24df20cebdeb849c2c5fc27be21396aaf71e76e9eb47e3aba26e87729ad00e0aeaedffb21a98b8ed0bd7e159fb3ac43903b81c256653dc  tpm-1.3.tar.gz"