Rollup merge of #100852 - Samyak2:samyak/100459, r=Mark-Simulacrum
Use `getuid` to check instead of `USER` env var in rustbuild This makes it consistent with `x.py` as changed in #95671 Fixes #100459
This commit is contained in:
commit
b05f97d594
2 changed files with 11 additions and 4 deletions
|
@ -793,6 +793,8 @@ class RustBuild(object):
|
|||
|
||||
def check_vendored_status(self):
|
||||
"""Check that vendoring is configured properly"""
|
||||
# keep this consistent with the equivalent check in rustbuild:
|
||||
# https://github.com/rust-lang/rust/blob/a8a33cf27166d3eabaffc58ed3799e054af3b0c6/src/bootstrap/lib.rs#L399-L405
|
||||
if 'SUDO_USER' in os.environ and not self.use_vendored_sources:
|
||||
if os.getuid() == 0:
|
||||
self.use_vendored_sources = True
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue