]> git.lizzy.rs Git - rust.git/blobdiff - src/bootstrap/install.rs
Add an optional condition to constrain defaults.
[rust.git] / src / bootstrap / install.rs
index 7b2d644c7696d44f56ff254e00c9aab98703fbdb..d2870832086e8d6ee9c47919c88b8d1301a505f4 100644 (file)
@@ -150,7 +150,8 @@ impl Step for $name {
             $(const $c: bool = true;)*
 
             fn should_run(run: ShouldRun) -> ShouldRun {
-                run.path($path)
+                let $builder = run.builder;
+                run.path($path).default_condition($default_cond)
             }
 
             fn make_run(
@@ -159,9 +160,6 @@ fn make_run(
                 host: Interned<String>,
                 target: Interned<String>,
             ) {
-                if path.is_none() && !($default_cond) {
-                    return;
-                }
                 $builder.ensure($name {
                     stage: $builder.top_stage,
                     target,