From c60c27cf3ce7b0a3f291325ade6ea81f0eb1f9e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=AE=B8=E6=9D=B0=E5=8F=8B=20Jieyou=20Xu=20=28Joe=29?= Date: Mon, 22 Jul 2024 19:00:05 +0000 Subject: [PATCH] [EXPERIMENTAL] plain no needs-llvm-components --- src/tools/tidy/src/allowed_run_make_makefiles.txt | 1 - tests/run-make/print-target-list/Makefile | 8 -------- tests/run-make/print-target-list/rmake.rs | 10 ++++++++++ 3 files changed, 10 insertions(+), 9 deletions(-) delete mode 100644 tests/run-make/print-target-list/Makefile create mode 100644 tests/run-make/print-target-list/rmake.rs diff --git a/src/tools/tidy/src/allowed_run_make_makefiles.txt b/src/tools/tidy/src/allowed_run_make_makefiles.txt index 2561df2e4772e..bca7040c370ff 100644 --- a/src/tools/tidy/src/allowed_run_make_makefiles.txt +++ b/src/tools/tidy/src/allowed_run_make_makefiles.txt @@ -26,7 +26,6 @@ run-make/pdb-buildinfo-cl-cmd/Makefile run-make/pgo-gen-lto/Makefile run-make/pgo-indirect-call-promotion/Makefile run-make/print-calling-conventions/Makefile -run-make/print-target-list/Makefile run-make/raw-dylib-alt-calling-convention/Makefile run-make/raw-dylib-c/Makefile run-make/redundant-libs/Makefile diff --git a/tests/run-make/print-target-list/Makefile b/tests/run-make/print-target-list/Makefile deleted file mode 100644 index f23c40d4281e3..0000000000000 --- a/tests/run-make/print-target-list/Makefile +++ /dev/null @@ -1,8 +0,0 @@ -include ../tools.mk - -# Checks that all the targets returned by `rustc --print target-list` are valid -# target specifications -all: - for target in $(shell $(BARE_RUSTC) --print target-list); do \ - $(BARE_RUSTC) --target $$target --print sysroot; \ - done diff --git a/tests/run-make/print-target-list/rmake.rs b/tests/run-make/print-target-list/rmake.rs new file mode 100644 index 0000000000000..a7314f43d8b3e --- /dev/null +++ b/tests/run-make/print-target-list/rmake.rs @@ -0,0 +1,10 @@ +//! Check that all targets returned by `--print target-list` are valid target specifications. + +use run_make_support::bare_rustc; + +fn main() { + let targets = bare_rustc().print("target-list").run().stdout_utf8(); + for target in targets.lines() { + bare_rustc().target(target).print("sysroot").run(); + } +}