# Contributor: Oleg Titov # Maintainer: Oleg Titov pkgname=xmrig pkgver=5.5.1 pkgrel=0 pkgdesc="XMRig is a high performance Monero (XMR) miner" url="https://xmrig.com/" arch="all !s390x !ppc64le !aarch64" # gets stuck on aarch64 builder 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="d85355b26456e322ee017e156eded22766e5e4d71cc046e6de5d8f5765e76675bb5c7deba57591746edab0fce33904244356797874c66634225540b3868d0c38 xmrig-5.5.1.tar.gz"