I am trying to start a Solana project on Windows. When I run cargo build
in cmd, it works fine; but for cargo build-bpf
, I get an error:
BPF SDK: \\?\C:\Users\HP\.local\share\solana\install\releases\1.9.4\solana-release\bin\sdk\bpf
Can't get home directory path: environment variable not found
I tried installing WSL, but when I run cargo build
or cargo build-bpf
, I get this error:
error: `rustc -vV` didn't have a line for `host:`, got:
How can I solve the problem?