Add options to --extern flag. This changes the `--extern` flag so that it can take a series of options that changes its behavior. The general syntax is `[opts ':'] name ['=' path]` where `opts` is a comma separated list of options. Two options are supported, `priv` which replaces `--extern-private` and `noprelude` which avoids adding the crate to the extern prelude. ```text --extern priv:mylib=/path/to/libmylib.rlib --extern noprelude:alloc=/path/to/liballoc.rlib ``` `noprelude` is to be used by Cargo's build-std feature in order to use `--extern` to reference standard library crates. This also includes a second commit which adds the `aux-crate` directive to compiletest. I can split this off into a separate PR if desired, but it helps with defining these kinds of tests. It is based on #54020, and can be used in the future to replace and simplify some of the Makefile tests. |
||
|---|---|---|
| .. | ||
| dynamic_lib | ||
| rmeta | ||
| build.rs | ||
| Cargo.toml | ||
| creader.rs | ||
| dependency_format.rs | ||
| dynamic_lib.rs | ||
| foreign_modules.rs | ||
| lib.rs | ||
| link_args.rs | ||
| locator.rs | ||
| native_libs.rs | ||