archrelease: copy trunk to community-x86_64
[ArchLinux/community.git] / xmrig / trunk / PKGBUILD
blobe71feff6d8db5a9f0652225c354b2a04dd68df84
1 # Maintainer: kpcyrd <kpcyrd[at]archlinux[dot]org>
2 # Contributor: Konstantin Shalygin <k0ste@k0ste.ru>
4 pkgname=xmrig
5 pkgver=6.19.2
6 pkgrel=1
7 pkgdesc='RandomX, KawPow, CryptoNight, AstroBWT and GhostRider unified CPU/GPU miner and RandomX benchmark'
8 url='https://github.com/xmrig/xmrig'
9 arch=('x86_64')
10 license=('GPL3')
11 depends=('libuv' 'openssl' 'hwloc')
12 makedepends=('cmake')
13 backup=("etc/${pkgname}/${pkgname}.conf")
14 source=(https://github.com/xmrig/${pkgname}/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz
15         xmrig@.service
16         xmrig.sysusers)
17 sha256sums=('84b7d1cc0bb818d471d47a5e663839ae8ba8b8a3b641e227b03903125446e12c'
18             'bbc54b04a7da5ea473eb7d976307eb995fbfd96f0d012f1553b8c487182d9fb3'
19             'd8f499302fb2b642fe02586c81c410a299e0a6e133aef1cc1c783bcdcb3f44f6')
21 prepare() {
22   cd "${pkgname}-${pkgver}"
23   mkdir -p build
26 build() {
27   cd "${pkgname}-${pkgver}/build"
28   cmake .. -DCMAKE_BUILD_TYPE=Release
29   make
32 package() {
33   cd "${pkgname}-${pkgver}"
34   install -Dm775 "build/${pkgname}" -t "${pkgdir}/usr/bin"
35   install -Dm644 "src/config.json" "${pkgdir}/etc/${pkgname}/xmrig.conf"
36   install -Dm644 "${srcdir}/${pkgname}@.service" -t "${pkgdir}/usr/lib/systemd/system"
37   install -Dm0644 "${srcdir}/${pkgname}.sysusers" -t "${pkgdir}/usr/lib/sysusers.d"
40 # vim: ts=2 sw=2 et: