Migrate `run-make/dep-graph` to `rmake.rs`

This commit is contained in:
Guillaume Gomez 2024-06-15 13:00:20 +02:00
parent 8217b412a2
commit a4eaf87982
3 changed files with 18 additions and 13 deletions

View File

@ -25,7 +25,6 @@ run-make/cross-lang-lto-upstream-rlibs/Makefile
run-make/cross-lang-lto/Makefile
run-make/debug-assertions/Makefile
run-make/debugger-visualizer-dep-info/Makefile
run-make/dep-graph/Makefile
run-make/dep-info-doesnt-run-much/Makefile
run-make/dep-info-spaces/Makefile
run-make/dep-info/Makefile

View File

@ -1,12 +0,0 @@
include ../tools.mk
# ignore-cross-compile
# Just verify that we successfully run and produce dep graphs when requested.
all:
RUST_DEP_GRAPH=$(TMPDIR)/dep-graph $(RUSTC) \
-Cincremental=$(TMPDIR)/incr \
-Zquery-dep-graph -Zdump-dep-graph foo.rs
test -f $(TMPDIR)/dep-graph.txt
test -f $(TMPDIR)/dep-graph.dot

View File

@ -0,0 +1,18 @@
// Just verify that we successfully run and produce dep graphs when requested.
//@ ignore-cross-compile
use run_make_support::{path, rustc};
fn main() {
rustc()
.input("foo.rs")
.incremental(path("incr"))
.arg("-Zquery-dep-graph")
.arg("-Zdump-dep-graph")
.env("RUST_DEP_GRAPH", path("dep-graph"))
.run();
assert!(path("dep-graph.txt").is_file());
assert!(path("dep-graph.dot").is_file());
}