Skip to content

Bootstrap should support build directories within an unrelated git repository #102562

Closed
@jyn514

Description

@jyn514

#98483 recently broke the case where the source directory is built from a git clone, but the build directory is inside a different, unrelated git clone. Bootstrap shouldn't have opinions on where the build directory is; we should fix it.

We can detect this case by seeing if config.src.join("src").join("stage0.json") is present; if not, we guessed the source directory incorrectly and we should fallback to the old logic using CARGO_MANIFEST_DIR.

Originally posted by @cr1901 in #98483 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.regression-untriagedUntriaged performance or correctness regression.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions