Skip to content

Commit 7635e7c

Browse files
committed
Auto merge of #125579 - Noratrieb:print-host, r=davidtwco
Add `--print host-tuple` to print host target tuple People often parse `-vV` output to get to the host tuple, which is annoying to do. It's easier to just get it directly. I called it "host-tuple" instead of "host" because it's clearer that it's just the target name. I'm open to different names, but I think this one is fine. a quick GitHub search for `'^host` reveals many instances of people doing the parsing, for example: https://github.com/japaric/xargo/blob/68e0ca57cd90837fe02f262f074182f9cfeb6227/README.md?plain=1#L369 https://github.com/taiki-e/setup-cross-toolchain-action/blob/0e38473b0c562d6db19a98d3ec20a80f7ac189ae/main.sh#L96 https://github.com/taiki-e/cargo-llvm-cov/blob/8a3553b86551eabf9c30c060b1f72a5bbccb98c6/README.md?plain=1#L625 https://github.com/SiliconLabs/cpc-nvm3/blob/43f3ec39709b30700ef7f39d91fa647974323bf1/do.sh#L35 needs a compiler FCP. I could also do an MCP but I think just an FCP here makes the most sense.
2 parents e0c4846 + e13d480 commit 7635e7c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/machine.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -691,7 +691,7 @@ impl<'tcx> MiriMachine<'tcx> {
691691
clock: Clock::new(config.isolated_op == IsolatedOp::Allow),
692692
#[cfg(unix)]
693693
native_lib: config.native_lib.as_ref().map(|lib_file_path| {
694-
let target_triple = tcx.sess.opts.target_triple.triple();
694+
let target_triple = tcx.sess.opts.target_triple.tuple();
695695
// Check if host target == the session target.
696696
if env!("TARGET") != target_triple {
697697
panic!(

0 commit comments

Comments
 (0)