Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of rust-lang#71964 - jcotton42:bootstrap_decode_none_win…
…dows, r=Mark-Simulacrum Fix bootstrap failing on win32 ```powershell python x.py -h # or really any x.py command ``` would fail with ``` info: Downloading and building bootstrap before processing --help command. See src/bootstrap/README.md for help with common commands. Updating only changed submodules Submodules updated in 0.15 seconds Traceback (most recent call last): File "x.py", line 11, in <module> bootstrap.main() File "C:\Users\Joshua\Projects\forks\rust\src\bootstrap\bootstrap.py", line 960, in main bootstrap(help_triggered) File "C:\Users\Joshua\Projects\forks\rust\src\bootstrap\bootstrap.py", line 925, in bootstrap build.build = args.build or build.build_triple() File "C:\Users\Joshua\Projects\forks\rust\src\bootstrap\bootstrap.py", line 731, in build_triple return default_build_triple() File "C:\Users\Joshua\Projects\forks\rust\src\bootstrap\bootstrap.py", line 184, in default_build_triple ostype = require(["uname", "-s"], exit=required).decode(default_encoding) AttributeError: 'NoneType' object has no attribute 'decode' ``` This PR defers the `decode` call until after we're sure `ostype` and `cputype` are not `None`, as they would be on Windows since `uname` doesn't exist
- Loading branch information