summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 071cfb397121f34be5a809faedb327eb592a47c2 (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
38
39
40
41
# Maintainer: Tim DeHerrera <tim.de9@gmail.com>
pkgname=silentarmy-nvmod-git
pkgver=v5.29.g016f8e8
pkgrel=1
pkgdesc="GPU Zcash Equihash solver optimized for Nvidia and CUDA 8"
arch=('i686' 'x86_64')
url="https://github.com/krnlx/silentarmy-nvmod"
license=('MIT')
conflicts=('silentarmy' 'silentarmy-git')
provides=('silentarmy')
source=('git+https://github.com/krnlx/silentarmy-nvmod.git')
depends=('libclc' 'opencl-headers' 'python' 'opencl-nvidia')
md5sums=('SKIP')

_gitname='silentarmy-nvmod'

pkgver() {
  cd "$srcdir/$_gitname"
  echo "$(git describe | sed s/-/./g)"
}

build() {
  cd "$srcdir/$_gitname"

  # Inject CFLAGS from /etc/makepkg.conf
  sed -i "s/CFLAGS *= */&${CFLAGS} /" Makefile

  make ${MAKEFLAGS}
}

check() {
  cd "$srcdir/$_gitname"
  make test
}

package() {
  cd "$srcdir/$_gitname"
  mkdir -p "$pkgdir/usr/bin"
  install silentarmy "$pkgdir/usr/bin/"
  install sa-solver "$pkgdir/usr/bin/"
}