summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 877bb302ca3d320ec75302b52ee0656ca8414b13 (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
# Maintainer: Clar Charr <clar@charr.xyz>
pkgname=swc-hosts
pkgver=0.2.1
pkgrel=1
pkgdesc="Safely parse /etc/hosts from Someone Who Cares."
arch=(i686 x86_64)
url="https://github.com/clarcharr/$pkgname"
license=(CC0)
makedepends=(rust)
source=(git+https://github.com/clarcharr/$pkgname#$pgkver)
sha256sums=(SKIP)
validpgpkeys=(4BDA23A98EE4E049CBC3BA6C69DA5B388573EE35)
_binaries=(swc-hosts)
prepare() {
  cd $pkgname
  git tag --verify $pkgver
}
build() {
  cd "$srcdir/$pkgname"
  cargo build --release
}
package() {
  cd "$pkgdir"
  mkdir -p usr/bin
  for binary in ${_binaries[@]}; do
    install -m755 "$srcdir/$pkgname/target/release/$binary" usr/bin/$binary
  done
}