build-manifest: Add rust-mingw also as extension for "pc-windows-gnu" hosts.

This should enable `rustup component add --target aarch64-pc-windows-gnullvm rust-mingw` when running an `x86_64-pc-windows-gnullvm` toolchain (and vice-versa).

Which itself enables proper cross-compiling of Windows ARM64 binaries on a Windows x64 host without using commercial MSVC.
This commit is contained in:
Colin Finck
2026-01-07 12:06:37 +01:00
parent 74fd7516da
commit d2497820d0
+8
View File
@@ -282,6 +282,14 @@ fn target_host_combination(&mut self, host: &str, manifest: &Manifest) -> Option
PkgType::RustMingw => {
if host.contains("pc-windows-gnu") {
components.push(host_component(pkg));
extensions.extend(
TARGETS
.iter()
.filter(|&&target| {
target.contains("pc-windows-gnu") && target != host
})
.map(|target| Component::from_pkg(pkg, target)),
);
}
}
// Tools are always present in the manifest,