x.py doesn't respect --host when rustc is missing and building on windows
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
Summary
When building on Windows with x.py --host x86_64-pc-windows-msvc --target x86_64-pc-windows-msvc, and a rust compiler is not in $PATH, after failing to find a rust compiler, it falls back to autodetection, and downloads a x86_64-pc-windows-gnu compiler, ignoring the x86_64-pc-windows-msvc passed on the command line.
This doesn't happen when there a x86_64-pc-windows-msvc host rustc available in $PATH.
Operating system
Windows 2022
HEAD
4ad239f4156aa4e7df5ac9eb90ff0ab3d0089d1c
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the reported x.py command on Windows 2022 without a rustc in PATH, then trace the fallback from the failed compiler lookup into autodetection. Done means the explicitly supplied x86_64-pc-windows-msvc host is retained and the x86_64-pc-windows-gnu compiler is not selected.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100