Skip to content

--sysroot should be passed on to the linker #31180

@Zoxc

Description

@Zoxc

The linker needs to be passed the --sysroot option so it can find libraries when cross compiling.

I tried simply modifying rustc to pass the option on to the linker, but --sysroot is used during the bootstrap of rustc without an actual sysroot (i.e. there is only rust libraries, not C, so linking will fail).

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-feature-requestCategory: A feature request, i.e: not implemented / a PR.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions