cargo build
Compiling rsj-kv v0.1.0 (D:\devlop\ myFirstRustProgram)
error: linker `link.exe` not found
|
= note: 系统找不到指定的文件。 (os error 2)
note: the msvc targets depend on the msvc linker but `link.exe` was not found
报错信息表明编译目标依赖于MSVC(Microsoft Visual C++)链接器,但系统找不到link.exe。
解决方案
1.第一种情况如果cmd rustc -version 显示rust版本,只需要一条命令

文章讲述了在编译Rust程序时遇到的link.exe未找到的错误,提供了更新rust版本、安装MSVC工具链和配置环境变量的解决方案。
最低0.47元/天 解锁文章
447

被折叠的 条评论
为什么被折叠?



