Source code of the program:

fn main() { println!("Hello, world!"); } 

I'm trying to compile with static linking, but I get a window with an error:

 The code execution cannot be proceed because std-66ce4ddf5a45ca83.dll was not found. Reinstalling the program may fix this problem. 

I don’t understand what's the matter, I guess that the problem is with the library, but I don’t know how to fix it.

  • What does static linking mean? Rust by default makes files with dependencies only on kernel and vcruntime . What is your target? rustup show write? - aSpex
  • @aSpex Default host: x86_64-pc-windows-msvc | Active toolchain: stable-x86_64-pc-windows-msvc (default) - you have no pass
  • And how do you compile? Just cargo build ? In general, this dll should be in the folder with the Rasta binaries. Check there is she there in fact. The path can be found using the rustc --print sysroot command rustc --print sysroot . Check there is in the PATH variable the path c:\Users\%Name%\.cargo\bin Try reinstalling Rust. - aSpex
  • And by the way, do you have Microsoft Visual C ++ Build Tools 2017 installed? Or Visual Studio any? You can also try switching to x86_64-pc-windows-gnu . - aSpex
  • @aSpex yes, it is visual studio 2017, I compile it with the usual cargo build , I looked along the path .rustup\toolchains\stable-x86_64-pc-windows-msvc\bin and there really is this .dll , the PATH stands for C:\Users\%Name%\.cargo\bin . Everything should work perfectly, but does not work ... - you have no pass

0