Rust-GPU / Rust-CUDA

Ecosystem of libraries and tools for writing and executing fast GPU code fully in Rust.
Apache License 2.0
3.16k stars 120 forks source link

Prebuilt LLVM folder not existing anymore #102

Open locadani opened 1 year ago

locadani commented 1 year ago

I am experiencing some problems running the example program and after some time I think I figured out why. I also saw similar issues that might be solved after solving this problem. The folder pointed to by this variable doesn't exists. https://github.com/Rust-GPU/Rust-CUDA/blob/8a6cb734d21d5582052fa5b38089d1aa0f4d582f/crates/rustc_codegen_nvvm/build.rs#L13 Any ideas on how to fix this?

3togo commented 1 year ago

Did you solve the problem? I get the following error

  --- stderr
  thread 'main' panicked at 'Unsupported target with no matching prebuilt LLVM: `x86_64-unknown-linux-gnu`, install LLVM and set LLVM_CONFIG', crates/rustc_codegen_nvvm/build.rs:58:14
  stack backtrace:
locadani commented 1 year ago

No unfortunately, but I did some steps forward. You need to download the prebuilt llvm from here (link), then navigate to downloaded file and make it executable, finally set that as env variable LLVM_CONFIG. Doing this i get some linking problems: /usr/bin/ld: cannot find -lz: No such file or directory /usr/bin/ld: cannot find -ltinfo: No such file or directory collect2: error: ld returned 1 exit status

I solved them running sudo apt-get install libtinfo-dev sudo apt-get install zlib1g-dev sudo apt-get install libxml2-dev But now I have other errors from the cuda/cpu/add crate, that I am trying to solve