diff options
author | Felix Golatofski | 2020-06-03 21:27:32 +0200 |
---|---|---|
committer | Felix Golatofski | 2020-06-03 21:27:32 +0200 |
commit | c2d820f21af31a1365e8d5db8d2f60ee1c397341 (patch) | |
tree | a2f82680e97c34352373d4f81dbc5f7d0b6fb687 | |
parent | a9b92108a3e8ad2e0b19242ccea88ab30cfc50c9 (diff) | |
download | aur-xmr-stak-nvidia-git.tar.gz |
Updated: PKGBUILD
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | PKGBUILD | 56 | ||||
-rw-r--r-- | xmr-stak.service | 32 |
3 files changed, 73 insertions, 29 deletions
@@ -1,18 +1,22 @@ pkgbase = xmr-stak-nvidia-git - pkgdesc = Monero Miner (NVIDIA) - pkgver = r1457.67cf951 + pkgdesc = Free Monero RandomX Miner and unified CryptoNight miner (CUDA) + pkgver = 2.10.8.r0.g67cf951 pkgrel = 1 - url = https://github.com/fireice-urk/xmr-stak + url = https://github.com/fireice-uk/xmr-stak arch = x86_64 license = GPL3 makedepends = git makedepends = cmake + makedepends = opencl-headers depends = libmicrohttpd depends = openssl - depends = cuda depends = hwloc + depends = ocl-icd + depends = cuda source = git+https://github.com/fireice-uk/xmr-stak.git - sha512sums = SKIP + source = xmr-stak.service + sha256sums = SKIP + sha256sums = e0cbee0dab1c730e5deff31eddef84a635b4c9f33ba2368a446e62acc084649a pkgname = xmr-stak-nvidia-git @@ -1,48 +1,56 @@ -# Maintainer: GSI <2017 at groovy-skills dot com> +# Maintainer: +# Contributor: Felix Golatofski <contact@xdfr.de> +# Contributor: GSI <2017 at groovy-skills dot com> # Contributor: Saren Arterius <saren at wtako dot net> # Contributor: Hui Yiqun <huiyiqun at gmail dot com> + pkgname=xmr-stak-nvidia-git -pkgver=r1457.67cf951 +pkgver=2.10.8.r0.g67cf951 pkgrel=1 -pkgdesc="Monero Miner (NVIDIA)" +pkgdesc="Free Monero RandomX Miner and unified CryptoNight miner (CUDA)" arch=('x86_64') -url="https://github.com/fireice-urk/xmr-stak" +url="https://github.com/fireice-uk/xmr-stak" license=('GPL3') -makedepends=('git' 'cmake') -depends=('libmicrohttpd' 'openssl' 'cuda' 'hwloc') -source=('git+https://github.com/fireice-uk/xmr-stak.git') -sha512sums=('SKIP') - +makedepends=('git' 'cmake' 'opencl-headers') +depends=('libmicrohttpd' 'openssl' 'hwloc' 'ocl-icd' 'cuda') +source=("git+https://github.com/fireice-uk/xmr-stak.git" + 'xmr-stak.service') +sha256sums=('SKIP' + 'e0cbee0dab1c730e5deff31eddef84a635b4c9f33ba2368a446e62acc084649a') pkgver() { - cd "$srcdir/xmr-stak" - printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" + cd "$srcdir/xmr-stak" + git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' } -build() { - cd "$srcdir/xmr-stak" +prepare() { + cd "$srcdir/xmr-stak" - mkdir build - cd build + # create build dir + [ -d build ] || mkdir build +} + +build() { + cd "$srcdir/xmr-stak/build" # https://github.com/fireice-uk/xmr-stak/blob/master/doc/compile/compile_Linux.md cmake \ .. \ + -DCMAKE_C_COMPILER=/usr/bin/gcc-8 \ + -DCMAKE_CXX_COMPILER=/usr/bin/g++-8 \ -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_LINK_STATIC=OFF \ - -DCMAKE_BUILD_TYPE=Release \ - -DMICROHTTPD_ENABLE=ON \ - -DOpenSSL_ENABLE=ON \ - -DXMR-STAK_COMPILE=native \ -DCPU_ENABLE=ON \ - -DHWLOC_ENABLE=ON \ - -DOpenCL_ENABLE=OFF \ -DCUDA_ENABLE=ON - make } package() { - cd "xmr-stak/build" + cd "$srcdir/xmr-stak/build" make DESTDIR="$pkgdir/" install + + install -m755 -d $pkgdir/usr/lib/systemd/system + install -m644 $srcdir/xmr-stak.service $pkgdir/usr/lib/systemd/system + install -Dm644 README.md "$pkgdir/usr/share/doc/$pkgname/README.md" + + install -m755 -d $pkgdir/etc/xmr-stak } diff --git a/xmr-stak.service b/xmr-stak.service new file mode 100644 index 000000000000..97952cca69fa --- /dev/null +++ b/xmr-stak.service @@ -0,0 +1,32 @@ +[Unit] +Description=Unified all-in-one Monero miner +After=network-online.target +AssertFileNotEmpty=/etc/xmr-stak/config.txt + +[Service] +Environment=GPU_FORCE_64BIT_PTR=1 +Environment=GPU_MAX_HEAP_SIZE=100 +Environment=GPU_USE_SYNC_OBJECTS=1 +Environment=GPU_MAX_ALLOC_PERCENT=100 +Environment=GPU_SINGLE_ALLOC_PERCENT=100 +ExecStart=/usr/bin/xmr-stak --cpu /etc/xmr-stak/cpu.txt --amd /etc/xmr-stak/amd.txt --nvidia /etc/xmr-stak/nvidia.txt -c /etc/xmr-stak/config.txt -C /etc/xmr-stak/pools.txt +DynamicUser=true +Group=video +CPUSchedulingPolicy=idle +PrivateTmp=true +ProtectHome=true +ProtectSystem=strict +NoNewPrivileges=true +CapabilityBoundingSet= +MemoryDenyWriteExecute=true +ProtectKernelModules=true +ProtectKernelTunables=true +ProtectControlGroups=true +RestrictRealtime=true +RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX +RestrictNamespaces=true +PrivateUsers=true +ConfigurationDirectory=xmr-stak + +[Install] +WantedBy=multi-user.target |