summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 5bd13a643d6972592f6d377e9e6cf28c6f9e5eb2 (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
# Maintainer: Julien Nicoulaud <julien dot nicoulaud at gmail dot com>

pkgname=sampler
pkgver=1.0.3
pkgrel=1
pkgdesc='A tool for shell commands execution, visualization and alerting. Configured with a simple YAML file.'
arch=('i686' 'x86_64' 'armv7h' 'armv6h' 'aarch64')
url='https://sampler.dev'
license=('GPL3')
makedepends=('git' 'go-pie' 'alsa-lib')
conflicts=("${pkgname}-git")
source=("https://github.com/sqshq/sampler/archive/v${pkgver}.tar.gz")
sha256sums=('03aa155c04e02fa40097841515de4fbf57904142defe5433490e28792868842d')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  GOFLAGS="-gcflags=all=-trimpath=${PWD} -asmflags=all=-trimpath=${PWD} -ldflags=-extldflags=-zrelro -ldflags=-extldflags=-znow" go build
}

check() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  go test -v ./...
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  install -Dm755 "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
}