upgpkg: wordpress 6.2.1-1
[ArchLinux/community.git] / golang-github-stretchr-objx / trunk / PKGBUILD
blobc81d3e52f96fd985965b8611bcf590309229b625
1 # Maintainer: Felix Yan <felixonmars@archlinux.org>
3 pkgname=golang-github-stretchr-objx
4 pkgver=0.3.0
5 pkgrel=1
6 pkgdesc='Go package for dealing with maps, slices, JSON and other data.'
7 arch=('any')
8 url="https://github.com/stretchr/objx"
9 license=('MIT')
10 depends=('go')
11 checkdepends=('golang-github-stretchr-testify')
12 source=("$pkgname-$pkgver.tar.gz::https://github.com/stretchr/objx/archive/v$pkgver.tar.gz")
13 sha512sums=('bd831d8f44d7d3ef8ad32cada055c58b16ac7a87a8f142b58ce1bce4a2b2d7a45d285f4547b9b5c4cb8edf80fbf57fc61ca6d239a765a20d69e88b5cfbd62252')
15 check() {
16   export GO111MODULE=off
17   export GOPATH="$srcdir/build:/usr/share/gocode"
18   mkdir -p "$srcdir"/build/src/github.com/stretchr
19   cp -a "$srcdir"/objx-$pkgver "$srcdir"/build/src/github.com/stretchr/objx
20   cd "$srcdir"/build/src/github.com/stretchr/objx
21   go test -v $(go list ./...)
24 package() {
25   mkdir -p "$pkgdir"/usr/share/gocode/src/github.com/stretchr
26   cp -a "$srcdir"/objx-$pkgver "$pkgdir"/usr/share/gocode/src/github.com/stretchr/objx
28   install -Dm644 objx-$pkgver/LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE