diff options
| author | onur-ozkan <work@onurozkan.dev> | 2024-01-18 15:50:40 +0300 |
|---|---|---|
| committer | onur-ozkan <work@onurozkan.dev> | 2024-01-18 19:47:44 +0300 |
| commit | 21b4fe222f73e5f2b1791004071d73c19a63d08c (patch) | |
| tree | 3f4339f36b2040b2aa61be924ad88a53b1a3e4fb /src/bootstrap/bootstrap.py | |
| parent | c485ee71477a29041895c47cc441b364670f3772 (diff) | |
| download | rust-21b4fe222f73e5f2b1791004071d73c19a63d08c.tar.gz rust-21b4fe222f73e5f2b1791004071d73c19a63d08c.zip | |
Set RUSTC_BOOTSTRAP=1 consistently
Signed-off-by: onur-ozkan <work@onurozkan.dev>
Diffstat (limited to 'src/bootstrap/bootstrap.py')
| -rw-r--r-- | src/bootstrap/bootstrap.py | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/bootstrap/bootstrap.py b/src/bootstrap/bootstrap.py index 6f3be1f6e93..28d96cb1cfe 100644 --- a/src/bootstrap/bootstrap.py +++ b/src/bootstrap/bootstrap.py @@ -924,14 +924,17 @@ class RustBuild(object): # default toolchain is not nightly. # # But that setting has the collateral effect of rust-analyzer also - # passing RUSTC_BOOTSTRAP=1 to all x.py invocations too (the various - # overrideCommand). For compiling bootstrap, that is unwanted and can - # cause spurious rebuilding of bootstrap when rust-analyzer x.py - # invocations are interleaved with handwritten ones on the command line. - env.pop("RUSTC_BOOTSTRAP", None) - - # preserve existing RUSTFLAGS - env.setdefault("RUSTFLAGS", "") + # passing RUSTC_BOOTSTRAP=1 to all x.py invocations too (the various overrideCommand). + # For compiling bootstrap that can cause spurious rebuilding of bootstrap when + # rust-analyzer x.py invocations are interleaved with handwritten ones on the + # command line. + # + # Set RUSTC_BOOTSTRAP=1 consistently. + env["RUSTC_BOOTSTRAP"] = "1" + + default_rustflags = "" if env.get("RUSTFLAGS_BOOTSTRAP", "") else "-Zallow-features=" + + env.setdefault("RUSTFLAGS", default_rustflags) target_features = [] if self.get_toml("crt-static", build_section) == "true": |
