about summary refs log tree commit diff
path: root/src/liballoc/string.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2018-03-28 12:56:09 +0000
committerbors <bors@rust-lang.org>2018-03-28 12:56:09 +0000
commitd87c19db6df9189a2beb43e7998d0cc5548878b3 (patch)
treeae7874a05c5bbcd1609ef068f557a4ade505c5c4 /src/liballoc/string.rs
parentbcffdf1b6da161eecd761eb4a3ef703ff05c33f6 (diff)
parentb889f98fba63dfcce68902c3a8c330fdea16a33b (diff)
downloadrust-d87c19db6df9189a2beb43e7998d0cc5548878b3.tar.gz
rust-d87c19db6df9189a2beb43e7998d0cc5548878b3.zip
Auto merge of #49019 - phil-opp:target-spec, r=pnkfelix
Introduce a TargetTriple enum to support absolute target paths

This PR replaces target triple strings with a `TargetTriple` enum, which represents either a target triple or a path to a JSON target file. The path variant is used if the `--target` argument has a `.json` extension, else the target triple variant is used.

The motivation of this PR is support for absolute target paths to avoid the need for setting the `RUST_TARGET_PATH` environment variable (see rust-lang/cargo#4905 for more information). For places where some kind of triple is needed (e.g. in the sysroot folder), we use the file name (without extension).

For compatibility, we keep the old behavior of searching for a file named `$(target_triple).json` in `RUST_TARGET_PATH` for non-official target triples.
Diffstat (limited to 'src/liballoc/string.rs')
0 files changed, 0 insertions, 0 deletions