Skip to content

Commit 3e5b058

Browse files
committed
Make crate tests depend on their extern crates. Reorder TEST_HOST_CRATES in hopes of exposing future instances of this bug.
1 parent 7daea7c commit 3e5b058

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

mk/tests.mk

+7-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
# The names of crates that must be tested
1717
TEST_TARGET_CRATES = std extra
18-
TEST_HOST_CRATES = syntax rustc rustdoc rust rustpkg rusti
18+
TEST_HOST_CRATES = rust rusti rustpkg rustc rustdoc syntax
1919
TEST_CRATES = $(TEST_TARGET_CRATES) $(TEST_HOST_CRATES)
2020

2121
# Markdown files under doc/ that should have their code extracted and run
@@ -352,27 +352,33 @@ $(3)/stage$(1)/test/rustctest-$(2)$$(X_$(2)): \
352352
$(3)/stage$(1)/test/rustpkgtest-$(2)$$(X_$(2)): \
353353
$$(RUSTPKG_LIB) $$(RUSTPKG_INPUTS) \
354354
$$(SREQ$(1)_T_$(2)_H_$(3)) \
355+
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBSYNTAX_$(2)) \
355356
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTC_$(2))
356357
@$$(call E, compile_and_link: $$@)
357358
$$(STAGE$(1)_T_$(2)_H_$(3)) -o $$@ $$< --test
358359

359360
$(3)/stage$(1)/test/rustitest-$(2)$$(X_$(2)): \
360361
$$(RUSTI_LIB) $$(RUSTI_INPUTS) \
361362
$$(SREQ$(1)_T_$(2)_H_$(3)) \
363+
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBSYNTAX_$(2)) \
362364
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTC_$(2))
363365
@$$(call E, compile_and_link: $$@)
364366
$$(STAGE$(1)_T_$(2)_H_$(3)) -o $$@ $$< --test
365367

366368
$(3)/stage$(1)/test/rusttest-$(2)$$(X_$(2)): \
367369
$$(RUST_LIB) $$(RUST_INPUTS) \
368370
$$(SREQ$(1)_T_$(2)_H_$(3)) \
371+
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTPKG_$(2)) \
372+
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTDOC_$(2)) \
373+
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTI_$(2)) \
369374
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTC_$(2))
370375
@$$(call E, compile_and_link: $$@)
371376
$$(STAGE$(1)_T_$(2)_H_$(3)) -o $$@ $$< --test
372377

373378
$(3)/stage$(1)/test/rustdoctest-$(2)$$(X_$(2)): \
374379
$$(RUSTDOC_LIB) $$(RUSTDOC_INPUTS) \
375380
$$(SREQ$(1)_T_$(2)_H_$(3)) \
381+
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBSYNTAX_$(2)) \
376382
$$(TLIB$(1)_T_$(2)_H_$(3))/$$(CFG_LIBRUSTC_$(2))
377383
@$$(call E, compile_and_link: $$@)
378384
$$(STAGE$(1)_T_$(2)_H_$(3)) -o $$@ $$< --test

0 commit comments

Comments
 (0)