Skip to content

compiletest does not pass --extern flags #53737

Closed
@nikomatsakis

Description

@nikomatsakis

In #51456, @qmx and I noticed that compiletest, when using aux-build libraries, simply supplies the compiler with -L instead of using the --extern lib_name=path-to-rlib compiler argument form. This is a shame because the latter form is what cargo actually uses in practice!

We ought to add another comment form to use the latter. Something like:

// aux-build:lib_name=file.rs

or perhaps a different header name.

(We could also retrofit the existing aux-build to use --extern, but it seems useful to be able to test in both modes, actually, so I'd prefer to add something new.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-compiletestArea: The compiletest test runnerA-testsuiteArea: The testsuite used to check the correctness of rustcC-enhancementCategory: An issue proposing an enhancement or a PR with one.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions