fireice-uk / xmr-stak

Free Monero RandomX Miner and unified CryptoNight miner
GNU General Public License v3.0
4.05k stars 1.79k forks source link

xmr-stak didn't see cuda backend library on some linux distributions starting from 2.9.0 version #2403

Open Zenitur opened 5 years ago

Zenitur commented 5 years ago

There are my builds of xmr-stak 2.8.3 and 2.9.0. 2.8.3 version is successfully see libxmrstak_cuda_backend.so library. 2.9.0 version didn't see that on openSUSE Linux, but it's see that on Gentoo Linux. xmr-stak says "no such file or directory" however file exists. It didn't see only CUDA backend file however it see OpenCL and CPU backend libraries.

I cannot test commits between 2.8.3 and 2.9.0 because the build is broken there. I think It could be broken there or there.

The last version I tested is 2.10.4 and it's still doesn't working.

valeradyomin commented 5 years ago

Same shit with MacOs. -> https://github.com/fireice-uk/xmr-stak/issues/2281#issuecomment-481342283

Still no any solution.

psychocrypt commented 5 years ago

please try the latest release 2.10.4

Zenitur commented 5 years ago

@psychocrypt versions 2.9.0 - 2.10.4 are affected. My build is working on Gentoo but didn't working on openSUSE

I'd found the commit that breaking CUDA. There is it: https://github.com/fireice-uk/xmr-stak/commit/1cb5214519e08e9e0ec0ba4b58c6becd841003a9 I'd tried to return changes in CMakeLists.txt in 2.10.4, now I have:

[2019-05-25 23:56:18] : NVIDIA: try to load library 'xmrstak_cuda_backend'
NVIDIA: found 1 potential device's
./xmr-stak: symbol lookup error: ./libxmrstak_cuda_backend.so: undefined symbol: cuInit

With non-modified CMake I have:

[2019-05-25 23:56:18] : NVIDIA: try to load library 'xmrstak_cuda_backend'
WARNING: NVIDIA cannot load backend library: libxmrstak_cuda_backend_cuda.so: cannot open shared object file: No such file or directory
MCip23 commented 5 years ago

Me too have the same issue in Mint environment. 2.8.3 detects, 2.10.x doesn't.

psychocrypt commented 5 years ago

the problem is that the nvrtc libraries are not found. The LD_LIBRARY_PATH to rhe cuda nvrtc library and it works. The curren dev has a falg to compile it without the need of those lubraries but than cryptonigh_r will not be supported.

Zenitur commented 5 years ago

Do I need to revert changes in CMakeLists.txt before set LD_LIBRARY_PATH to nvrtx libraries? Or xmr-stak will see it without reverting changes?

psychocrypt commented 5 years ago

There is no need ever to change CMakeLists.txt Set the environment variable and execute your compiled binary