Skip to content

Commit

Permalink
Auto merge of #109770 - jyn514:run-make-fulldeps, r=Mark-Simulacrum
Browse files Browse the repository at this point in the history
Move almost all run-make-fulldeps tests to run-make

They pass fine, and this avoids having to build the compiler twice.

There are few enough tests left that I think it should be possible to get rid of this test suite altogether, but I expect this PR to fail at least a few times in bors and want to get it merged before tackling further changes. cc #83775

Fixes #66085. Fixes #83773.
  • Loading branch information
bors committed Apr 3, 2023
2 parents a93bcdc + c45037b commit 3328913
Show file tree
Hide file tree
Showing 774 changed files with 226 additions and 95 deletions.
2 changes: 1 addition & 1 deletion tests/run-make-fulldeps/hotplug_codegen_backend/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../tools.mk
include ../../run-make/tools.mk

# ignore-stage1

Expand Down
2 changes: 1 addition & 1 deletion tests/run-make-fulldeps/issue-19371/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../tools.mk
include ../../run-make/tools.mk

# This test ensures that rustc compile_input can be called twice in one task
# without causing a panic.
Expand Down
5 changes: 0 additions & 5 deletions tests/run-make-fulldeps/issue-25581/Makefile

This file was deleted.

2 changes: 1 addition & 1 deletion tests/run-make-fulldeps/obtain-borrowck/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../tools.mk
include ../../run-make/tools.mk

# This example shows how to implement a rustc driver that retrieves MIR bodies
# together with the borrow checker information.
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make-fulldeps/pretty-expanded/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../tools.mk
include ../../run-make/tools.mk

all:
$(RUSTC) -o $(TMPDIR)/input.expanded.rs -Zunpretty=expanded input.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# Test that if we build `b` against a version of `a` that has one set
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# Test that -A warnings makes the 'empty trait list for derive' warning go away
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# Test that -A warnings makes the 'empty trait list for derive' warning go away
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# ignore-macos
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# ignore-macos
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(TMPDIR)/$(call BIN,bar)
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# ignore-freebsd
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,cfoo)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,cfoo)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: archive
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,add)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

TARGET_SYSROOT := $(shell $(RUSTC) --print sysroot)/lib/rustlib/$(TARGET)/lib
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
# Test that allocator-related symbols don't show up as exported from a cdylib as
# they're internal to Rust and not part of the public ABI.

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call RUN_BINFILE,foo)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
include ../tools.mk

# ignore-wasm32 (need a C compiler)
# ignore-wasm64 (need a C compiler)

all: $(TMPDIR)/libnative.a
mkdir -p $(TMPDIR)/crate
mkdir -p $(TMPDIR)/native
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/const_fn_mir/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

all:
$(RUSTC) main.rs --emit=mir -o "$(TMPDIR)"/dump.mir
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/coverage/coverage_tools.mk
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
#
# include ../coverage/coverage_tools.mk

include ../../run-make-fulldeps/tools.mk
include ../tools.mk
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
include ../../run-make-fulldeps/tools.mk
# ignore-cross-compile
include ../tools.mk

# Ensure that crates compiled with different rustc versions cannot
# be dynamically linked.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/dep-graph/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# ignore-cross-compile

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
include ../../run-make-fulldeps/tools.mk
# ignore-cross-compile
include ../tools.mk

# Check that valid binaries are persisted by running them, regardless of whether the --run or --no-run option is used.

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/dump-mono-stats/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

all:
$(RUSTC) --crate-type lib foo.rs -Z dump-mono-stats=$(TMPDIR) -Zdump-mono-stats-format=json
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/emit-named-files/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

OUT=$(TMPDIR)/emit

Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/emit-path-unhashed/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

OUT=$(TMPDIR)/emit

Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/emit-shared-files/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

INVOCATION_ONLY = $(TMPDIR)/invocation-only
TOOLCHAIN_ONLY = $(TMPDIR)/toolchain-only
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/env-dep-info/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# FIXME(eddyb) provide `HOST_RUSTC` and `TARGET_RUSTC`
# instead of hardcoding them everywhere they're needed.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/export-executable-symbols/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# ignore-wasm32
# ignore-wasm64
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# Attempt to build this dependency tree:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# Test mixing pathless --extern with paths.
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,test)
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,test)
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# ignore-windows-msvc
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,test)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,ctest)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,test)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,ctest)
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all:
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/fmt-write-bloat/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# ignore-windows

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: foo
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: foo
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
# ignore-i686-pc-windows-gnu

# This test doesn't work on 32-bit MinGW as cdylib has its own copy of unwinder
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# ignore-windows
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
# only-gnu
# only-linux

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# rust-lang/rust#70924: Test that if we add rust-src component in between two
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/incr-foreign-head-span/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# ignore-none no-std is not supported
# ignore-nvptx64-nvidia-cuda FIXME: can't find crate for 'std'
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/incr-prev-body-beyond-eof/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# ignore-none no-std is not supported
# ignore-nvptx64-nvidia-cuda FIXME: can't find crate for `std`

include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# Tests that we don't ICE during incremental compilation after modifying a
# function span such that its previous end line exceeds the number of lines
Expand Down
2 changes: 1 addition & 1 deletion tests/run-make/incremental-session-fail/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

SESSION_DIR := $(TMPDIR)/session
OUTPUT_FILE := $(TMPDIR)/build-output
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

# The rust crate foo will link to the native library foo, while the rust crate
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/invalid-so/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

DYLIB_NAME := $(shell echo | $(RUSTC) --crate-name foo --crate-type dylib --print file-names -)

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/run-make/issue-10971-temps-dir/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
include ../../run-make-fulldeps/tools.mk
include ../tools.mk

# Regression test for issue #10971
# Running two invocations in parallel would overwrite each other's temp files.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
# This test ensures that if you have the same rlib or dylib at two locations
# in the same path that you don't hit an assertion in the compiler.
#
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
include ../tools.mk

# ignore-cross-compile

# Test to make sure that reachable extern fns are always available in final
# productcs, including when LTO is used. In this test, the `foo` crate has a
# reahable symbol, and is a dependency of the `bar` crate. When the `bar` crate
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# ignore-cross-compile
include ../tools.mk

all: $(call NATIVE_STATICLIB,foo)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 3328913

Please sign in to comment.