GithubHelp home page GithubHelp logo

Comments (13)

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024 1

I have one compiled on Debian testing cuda 11. If you want you can try it out.
libxmrig-cuda.so.zip

from xmrig-cuda.

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024 1

Sorry for the late reply.

On Debian testing/bullseye for GTX1050 or higher (NO legacy drivers):
All official debian testing/bullseye repo's with main contrib non-free enabled.

  1. install/check if git build-essential cmake libuv1-dev libssl-dev and libhwloc-dev are installed.
  2. install/check if proprietary non-free nvidia-driver libcuda1 and nvidia-smi are installed (it should install all the relevant drivers needed).
  3. install nvidia-cuda-toolkit (this should install the cuda driverw needed)
  4. reboot if neccessary
  5. open a teminal.
  6. mkdir github
  7. cd github
  8. git clone https://github.com/xmrig/xmrig-cuda.git
  9. mkdir xmrig-cuda/build && cd xmrig-cuda/build
  10. cmake .. -DCUDA_TOOLKIT_ROOT_DIR=/usr/lib/nvidia-cuda-toolkit
  11. make -j$(nproc)
  12. Wait till everything is finished as it may take a while depending on your system.
  13. Ignore warnings
  14. If build is succesfull you have a libxmrig-cuda.so in the build directory.
  15. cp/move libxmrig-cuda.so to the directory where xmrig is installed/untarred

I am in the proces making a script for myself which checks/installs the required packages and compiles the lot, but I want to make sure it's working correctly and compiles libxmrig-cuda.so reproducible.

Hope the above helps.

from xmrig-cuda.

aleqx avatar aleqx commented on May 29, 2024

@DeeDeeRanged thanks for the kind offer, but I was making the point that these should be published with each release automatically for all to benefit (auto builders can do that).

from xmrig-cuda.

krishnaTORQUE avatar krishnaTORQUE commented on May 29, 2024

I have one compiled on Debian testing cuda 11. If you want you can try it out.
libxmrig-cuda.so.zip

Can you please share those commands step by step?

from xmrig-cuda.

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024

@DeeDeeRanged thanks for the kind offer, but I was making the point that these should be published with each release automatically for all to benefit (auto builders can do that).

You would need a variety of nvidia cards as cuda ranges from cuda 8 to cuda 11. Haven't seen any cuda 12 yet on linux.

from xmrig-cuda.

Spudz76 avatar Spudz76 commented on May 29, 2024

It's a bit more involved since for the library to work there would have to be versions built for every Ubuntu and every CUDA toolkit which means like 11 * (14, 16, 18, 20, 21) = 55 different builds. As opposed to one build per CUDA toolkit for Windows because Windows DLLs load on whatever Windows version just fine (no glibc or other basic kernels changing).

Better scripts to walk-through the building yourself are probably the real answer.

from xmrig-cuda.

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024

I figured it was something like that. It's one of the reasons I am trying to make a script that might work on different versions of Debian/Ubuntu. With the walkthrough I've tried to be as clear/sensible as I could be as I don't know the level of skills of ppl.

from xmrig-cuda.

bigmac5753 avatar bigmac5753 commented on May 29, 2024

This command cmake .. -DCUDA_LIB=/usr/lib/x86_64-linux-gnu/stubs/libcuda.so -DCUDA_TOOLKIT_ROOT_DIR=/usr/lib/nvidia-cuda-toolkit
gives this error:

  Could NOT find CUDA (missing: CUDA_NVCC_EXECUTABLE CUDA_INCLUDE_DIRS
  CUDA_CUDART_LIBRARY) (Required is at least version "8.0")
Call Stack (most recent call first):
  /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE)
  /usr/share/cmake-3.16/Modules/FindCUDA.cmake:1104 (find_package_handle_standard_args)
  cmake/CUDA-Version.cmake:14 (find_package)
  CMakeLists.txt:3 (include)

from xmrig-cuda.

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024

Which distro and videocard? Are "git build-essential cmake libuv1-dev libssl-dev libhwloc-dev nvidia-driver libcuda1 and nvidia-smi" installed, check if /usr/lib/x86_64-linux-gnu/stubs/libcuda.so and /usr/lib/nvidia-cuda-toolkit are available.

from xmrig-cuda.

Spudz76 avatar Spudz76 commented on May 29, 2024

CUDA Toolkit is usually in /usr/local/cuda or /usr/local/cuda-11.4 (or whichever version) if the symlink wasn't generated.

Do not supply anything but the CUDA_TOOLKIT_ROOT_DIR, *_LIB are intended to be set internally not overridden (if the rootdir doesn't work by itself, the toolkit is broken/incomplete).

from xmrig-cuda.

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024

@Spudz76

CUDA Toolkit is usually in /usr/local/cuda or /usr/local/cuda-11.4 (or whichever version) if the symlink wasn't generated.

Do not supply anything but the CUDA_TOOLKIT_ROOT_DIR, *_LIB are intended to be set internally not overridden (if the rootdir doesn't work by itself, the toolkit is broken/incomplete).

You are correct abt. only using -DCUDA_TOOLKIT_ROOT_DIR=/usr/lib/nvidia-cuda-toolkit just did a build and it works on both my Debian systems.

The instructions on https://xmrig.com/docs/miner/build/ubuntu are for Ubuntu with the cuda downloaded/installed from Nvidia directly and derived the build instructions from there to use it with Debian official repositories.

Thanks for the pointer.

from xmrig-cuda.

Spudz76 avatar Spudz76 commented on May 29, 2024

To mess things up more, I use the Nvidia packages but have put them on my own repo mirror so it picks them up off the Internet. Similar to if Nvidia themselves bothered to host a live repo...

But the result is functionally the same as using the Nvidia installer minus the "local repo" hack it uses.

And thus I don't really know where the Debian upstream cuda goes, it's old-ish so I've always ignored it. Maybe the search locations need updated so there is less need to specify the ROOT.

from xmrig-cuda.

DeeDeeRanged avatar DeeDeeRanged commented on May 29, 2024

You'll find video drivers and so on depending if your running stable + backports or testing in line with ubuntu and are quite uptodate.
Just checked ubuntu is putting the nvidia-toolkit also in the same place as debian. So for debian and ubuntu using the drivers and toolkit from the debian/ubuntu repos works fine. No need to use the ones from nvidia direct.

from xmrig-cuda.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.