diff options
| author | Trevor Gross <tmgross@umich.edu> | 2025-07-04 19:42:18 -0500 |
|---|---|---|
| committer | Trevor Gross <tmgross@umich.edu> | 2025-07-04 21:09:56 -0500 |
| commit | 016bc61312b85fae0f0f53c56946239b712b4604 (patch) | |
| tree | 2530aca1ca58b4327e15df53e72c5b1c47f0b0fc /library/compiler-builtins/crates/josh-sync/src | |
| parent | 19ab6461fbb1d9c05c3a6b6cdbaf9ffcd0f1c8d9 (diff) | |
| download | rust-016bc61312b85fae0f0f53c56946239b712b4604.tar.gz rust-016bc61312b85fae0f0f53c56946239b712b4604.zip | |
Test building custom targets and resolve an issue probing `rustc`
The `rustc` probe done in our build scripts needs to pass `--target` to get the correct configuration, which usually comes from the `TARGET` environment variable. However, for targets specified via a `target.json` file, `TARGET` gets set to the file name without an extension or path. `rustc` will check a search path to attempt to locate the file, but this is likely to fail since the directory where Cargo invokes build scripts (and hence where those scripts invoke `rustc`) might not have any relation to the JSON spec file. Resolve this for now by leaving `f16` and `f128` disabled if the `rustc` command fails. Result of the discussion at CARGO-14208 may eventually provide a better solution. A CI test is also added since custom JSON files are an edge case that could fail in other ways. I verified this fails without the fix here. The JSON file is the output for `thumbv7em-none-eabi`, just renamed so `rustc` doesn't identify it.
Diffstat (limited to 'library/compiler-builtins/crates/josh-sync/src')
0 files changed, 0 insertions, 0 deletions
