summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ec1e6d8914c024cf98f32e2617d3d3335a9e80a3 (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
37
# Maintainer: Axel McLaren <scm(at)axml(dot)uk>

pkgname=bed
pkgver=0.2.7
pkgrel=1
pkgdesc="binary editor written in Go"
arch=('x86_64' 'i686' 'aarch64')
url="https://github.com/itchyny/bed"
license=('MIT')
depends=('glibc')
makedepends=('go')

source=("${pkgname}-${pkgver}.tar.gz::https://github.com/itchyny/bed/archive/v${pkgver}.tar.gz")
sha256sums=('dea9265b5a78e91851059c1c726ac40490825f107f8db6ae7db67965b92599c3')
_goname="github.com/itchyny/bed"


build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  export GOPATH="${srcdir}"
  export CGO_CPPFLAGS="${CPPFLAGS}"
  export CGO_CFLAGS="${CFLAGS}"
  export CGO_CXXFLAGS="${CXXFLAGS}"
  export CGO_LDFLAGS="${LDFLAGS}"

  make build
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  install -Dm755 bed "${pkgdir}/usr/bin/bed"

  install -Dm644 README.md "${pkgdir}/usr/share/doc/${pkgname}/README.md"
  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}