rust/compiler/rustc_session/src
bors c55c26cb36 Auto merge of #83800 - xobs:impl-16351-nightly, r=nagisa
Add default search path to `Target::search()`

The function `Target::search()` accepts a target triple and returns a `Target` struct defining the requested target.

There is a `// FIXME 16351: add a sane default search path?` comment that indicates it is desirable to include some sort of default. This was raised in https://github.com/rust-lang/rust/issues/16351 which was closed without any resolution.

https://github.com/rust-lang/rust/pull/31117 was proposed, however that has platform-specific logic that is unsuitable for systems without `/etc/`.

This patch implements the suggestion raised in https://github.com/rust-lang/rust/issues/16351#issuecomment-180878193 where a `target.json` file may be placed in `$(rustc --print sysroot)/lib/rustlib/<target-triple>/target.json`. This allows shipping a toolchain distribution as a single file that gets extracted to the sysroot.
2021-05-09 22:01:26 +00:00
..
cgu_reuse_tracker.rs Make Diagnostic::span_fatal unconditionally raise an error 2021-05-08 23:12:04 -04:00
code_stats.rs mv compiler to compiler/ 2020-08-30 18:45:07 +03:00
config.rs Auto merge of #83800 - xobs:impl-16351-nightly, r=nagisa 2021-05-09 22:01:26 +00:00
filesearch.rs fix review 2021-02-25 04:21:12 +03:00
lib.rs Move SanitizerSet to rustc_target 2021-04-03 00:37:49 +03:00
options.rs Make -Z new-llvm-pass-manager an Option<bool> 2021-05-08 10:58:08 +02:00
output.rs Collapse all uses of target.options.foo into target.foo 2020-11-08 17:29:13 +03:00
parse.rs Remove (lots of) dead code 2021-03-27 22:16:33 -04:00
search_paths.rs use strip_prefix over starts_with and manual slicing based on pattern length (clippy::manual_strip) 2020-09-17 10:13:16 +02:00
session.rs Auto merge of #83800 - xobs:impl-16351-nightly, r=nagisa 2021-05-09 22:01:26 +00:00
utils.rs Implement RFC 2951: Native link modifiers 2021-05-05 16:04:25 -07:00