Skip to content

Better documentation about which libraries are linked by default by the rust compiler #139619

Open
@weiznich

Description

@weiznich

Location

Release notes, possibly the reference, not sure where else

Summary

There is currently no documentation about which system libraries are linked by rustc via the standard library and which of these libraries are guaranteed to be linked in the future. This was noticed while reporting #139352 and should likely be fixed before that change is stable.

Ideally there would be a list/table of linked libraries per target for at least tier 1 targets that contains all linked system libraries and also clarify which of these libraries are guaranteed to be linked in the future. (If none are guaranteed to be linked that's also fine, if that's stated explicitly). In addition it would be great to include documentation on how to test if your code relies on such not-guaranteed linkage. For windows that seems to be the command described by @ChrisDenton here. I'm not sure if similar commands exist for other platforms?

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsA-linkageArea: linking into static, shared libraries and binariesO-windowsOperating system: WindowsT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-libsRelevant to the library team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions