- 安装每日版本
rustup toolchain install nightly - 切换到每日版本
rustup default nightly - 安装
rust-src组件rustup component add rust-src --toolchain nightly-x86_64-pc-windows-msvc - 下载
https://github.com/PLC-lang/llvm-package-windows/releases/tag/v14.0.6解压后,设置LIBCLANG_PATH环境变量指向$LLVM_PATH\bin路径 安装该步骤好像不需要rustup target add x86_64-win7-windows-msvc- 使用命令
cargo build --release -Z build-std --target x86_64-win7-windows-msvc打包编译
其他命令
- 查看目标平台
rustc --print=target-list - 列表已按照的目标平台
rustup target list
