# Contributor: Oleg Titov # Maintainer: Oleg Titov pkgname=xmrig pkgver=3.2.0 pkgrel=0 pkgdesc="XMRig is a high performance Monero (XMR) miner" url="https://github.com/xmrig/xmrig" arch="all !s390x !ppc64le" license="GPL-3.0-or-later" options="!check" # No test suite from upstream makedepends="cmake libmicrohttpd-dev libuv-dev openssl-dev hwloc-dev" subpackages="$pkgname-doc" source="$pkgname-$pkgver.tar.gz::https://github.com/xmrig/xmrig/archive/v$pkgver.tar.gz" case "$CARCH" in aarch64*) CMAKE_CROSSOPTS="-DARM_TARGET=8"; makedepends="$makedepends linux-headers" ;; armv7*) CMAKE_CROSSOPTS="-DARM_TARGET=7"; makedepends="$makedepends linux-headers" ;; armhf*) CMAKE_CROSSOPTS="-DARM_TARGET=7"; makedepends="$makedepends linux-headers" ;; esac build() { mkdir build cd build cmake .. ${CMAKE_CROSSOPTS} make } package() { install -Dm 755 build/xmrig $pkgdir/usr/bin/xmrig install -Dm 644 -t "$pkgdir"/usr/share/doc/$pkgname/ README.md } sha512sums="21b8088807ef45f486b646f529e85cf709253b0edb25fd9d5e41decbd90a1115bef5c4590d0b0b8a803f86b0b154e3a48c3a34306c1b40a0d7630d163501d1ce xmrig-3.2.0.tar.gz"