aboutsummaryrefslogtreecommitdiffstats
path: root/community/age/APKBUILD
blob: 5939d91a74f010facd494c306cac9cded8c40990 (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
# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Contributor: Michał Polański <michal@polanski.me>
# Maintainer: Michał Polański <michal@polanski.me>
pkgname=age
pkgver=1.0.0
pkgrel=6
pkgdesc="Simple, modern and secure encryption tool"
url="https://github.com/FiloSottile/age"
license="BSD-3-Clause"
arch="all"
options="net" # for downloading Go modules
makedepends="go"
subpackages="$pkgname-doc"
source="https://github.com/FiloSottile/age/archive/v$pkgver/age-$pkgver.tar.gz"

export GOPATH="$srcdir"
export GOFLAGS="$GOFLAGS -trimpath -modcacherw"
export CGO_ENABLED=0

build() {
	mkdir bin
	go build -ldflags "-X main.Version=$pkgver" -o bin ./cmd/...
}

check() {
	go test ./...
}

package() {
	install -Dm755 -t "$pkgdir"/usr/bin bin/*
	install -Dm644 -t "$pkgdir"/usr/share/man/man1 doc/*.1
}

sha512sums="
77ea1af03a76339f4e934222bc9fc6119698080d0e03011c79b25119e0e8a1e6c0772ede5069cd63bde48cfaa4d355c897912741680e8b0c52d4c518182c2f7f  age-1.0.0.tar.gz
"