mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-04-05 09:27:19 +02:00
35 lines
986 B
Text
35 lines
986 B
Text
maintainer="Hoang Nguyen <folliekazetani@protonmail.com>"
|
|
pkgname=protoc-gen-go
|
|
pkgver=1.36.5
|
|
pkgrel=0
|
|
pkgdesc="Protocol Buffers Go generator"
|
|
url="https://github.com/protocolbuffers/protobuf-go"
|
|
arch="all"
|
|
license="BSD-3-Clause"
|
|
depends="protoc"
|
|
makedepends="go"
|
|
source="$pkgname-$pkgver.tar.gz::https://github.com/protocolbuffers/protobuf-go/archive/refs/tags/v$pkgver.tar.gz"
|
|
builddir="$srcdir/protobuf-go-$pkgver"
|
|
options="net" # download Go modules
|
|
|
|
export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
|
|
export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
|
|
export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
|
|
|
|
build() {
|
|
go build -v \
|
|
-ldflags "-X google.golang.org/protobuf/internal/version.PreRelease=" \
|
|
./cmd/protoc-gen-go/
|
|
}
|
|
|
|
check() {
|
|
go test ./...
|
|
}
|
|
|
|
package() {
|
|
install -Dm755 protoc-gen-go -t "$pkgdir"/usr/bin/
|
|
}
|
|
|
|
sha512sums="
|
|
19c42045781216fbcece6d2b7904e6cb65bc2f8070cf7befbb1215d10582307850c2b53178112279ad43238583a080a3e62eab6ecfff8e4f3b53c3883875a79b protoc-gen-go-1.36.5.tar.gz
|
|
"
|