archrelease: copy trunk to community-x86_64
[ArchLinux/community.git] / hey / trunk / PKGBUILD
blobe8b4404287bfb5652ba64f7d5f43d81d56b37f8c
1 # Maintainer: Jelle van der Waa <jelle@archlinux.org>
3 pkgname=hey
4 pkgver=0.1.4
5 pkgrel=5
6 pkgdesc='HTTP load generator'
7 url="https://github.com/rakyll/hey"
8 arch=(x86_64)
9 license=('GPL')
10 depends=('glibc')
11 makedepends=('go')
12 source=($pkgname-$pkgver.tar.gz::https://github.com/rakyll/hey/archive/v$pkgver.tar.gz
13         0001-Handle-Request.Host-containing-the-server-port.patch)
14 sha512sums=('f71ad13c401e9c9c45e1176924de49eb33df9b180dc10907997d1e500a4e5c6e28dd0293cef5d3fe8fabf0bfbade353938327bf3fce894c271209ec86e265ead'
15             '97c2e54d4f9b67c8beda5b3c034e501cdec9d6636bfaaf7d33a27927c96915b73906400dc2a17888144a4748a0f37462ccd2c90b35ca4f3221f3a410cf81af16')
17 prepare() {
18   cd $pkgname-$pkgver
19   patch -Np1 -i ${srcdir}/0001-Handle-Request.Host-containing-the-server-port.patch
22 build() {
23   cd $pkgname-$pkgver
24   go build \
25     -trimpath \
26     -buildmode=pie \
27     -mod=readonly \
28     -modcacherw \
29     -ldflags "-linkmode external -extldflags \"${LDFLAGS}\"" \
30     .
34 package() {
35   cd $pkgname-$pkgver
36   install -Dm755 $pkgname "$pkgdir"/usr/bin/$pkgname