Skip to content

Changes to RUSTC_BOOTSTRAP causes unwanted recompilations #467

Open
@weiznich

Description

@weiznich

I have a rather large project and I need to sometimes change RUSTC_BOOTSTRAP for some reasons. This causes proc_macro2 to recompile, which in turn recompile a large portion of our dependency tree. I personally find it quite surprising that this happens as this behavior is not documented anywhere.

Cargo verbose log:

      Dirty proc-macro2 v1.0.86: the env variable RUSTC_BOOTSTRAP changed
     Compiling proc-macro2 v1.0.86

Offending source code:

println!("cargo:rerun-if-env-changed=RUSTC_BOOTSTRAP");

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions