diff options
| author | bors <bors@rust-lang.org> | 2020-05-14 12:28:23 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-05-14 12:28:23 +0000 |
| commit | af6d8865fe0e1f6338c32cb3370802f2ebca0dc4 (patch) | |
| tree | 2fd89879edd8b151150a11ebfca69825885616d6 /src/bootstrap | |
| parent | 7c34d8d6629506a596215886e5fc4bb2b04b00ae (diff) | |
| parent | 56986bebc23788146dc46606d5af39b6354d6ad3 (diff) | |
| download | rust-af6d8865fe0e1f6338c32cb3370802f2ebca0dc4.tar.gz rust-af6d8865fe0e1f6338c32cb3370802f2ebca0dc4.zip | |
Auto merge of #72187 - RalfJung:rollup-a7a9jdi, r=RalfJung
Rollup of 12 pull requests Successful merges: - #71525 (`prefix` should not be mutable.) - #71741 (Pointer printing: do not print 0 offset) - #71870 (Be slightly more precise about any::type_name()'s guarantees.) - #71909 (Document From trait for Option implementations) - #71964 (Fix bootstrap failing on win32) - #72137 (Clean up E0581 explanation) - #72138 (Add doc comment for `rustc_middle::mir::mono::Linkage`) - #72150 (Remove UnnormalizedProjection) - #72151 (Update books) - #72163 (docs: remove comment referencing non-existent method) - #72169 (Clean up E0582 explanation) - #72183 (Fix Arc::decr_strong_count doc test) Failed merges: r? @ghost
Diffstat (limited to 'src/bootstrap')
| -rw-r--r-- | src/bootstrap/bootstrap.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/bootstrap/bootstrap.py b/src/bootstrap/bootstrap.py index 9a91f37c5de..b7d0fac5be3 100644 --- a/src/bootstrap/bootstrap.py +++ b/src/bootstrap/bootstrap.py @@ -180,13 +180,16 @@ def format_build_time(duration): def default_build_triple(): """Build triple as in LLVM""" default_encoding = sys.getdefaultencoding() - required = not sys.platform == 'win32' - ostype = require(["uname", "-s"], exit=required).decode(default_encoding) - cputype = require(['uname', '-m'], exit=required).decode(default_encoding) + required = sys.platform != 'win32' + ostype = require(["uname", "-s"], exit=required) + cputype = require(['uname', '-m'], exit=required) if ostype is None or cputype is None: return 'x86_64-pc-windows-msvc' + ostype = ostype.decode(default_encoding) + cputype = cputype.decode(default_encoding) + # The goal here is to come up with the same triple as LLVM would, # at least for the subset of platforms we're willing to target. ostype_mapper = { |
