about summary refs log tree commit diff
diff options
context:
space:
mode:
authorHideki Sekine <sekineh@me.com>2018-08-08 18:29:17 +0900
committerHideki Sekine <sekineh@me.com>2018-08-08 18:29:17 +0900
commit7c438d473211df10fd1f11e3a7813e740e05db00 (patch)
tree3ba3016832b703492abf472d242ba630e4fd1249
parent633832ffc2ba1c63b5ef797ab62bd7388c26ac4f (diff)
downloadrust-7c438d473211df10fd1f11e3a7813e740e05db00.tar.gz
rust-7c438d473211df10fd1f11e3a7813e740e05db00.zip
[CI] run-make/thumb: remove hacky workaround.
-rw-r--r--src/bootstrap/test.rs12
-rw-r--r--src/test/run-make/thumb-none-cortex-m/Makefile5
2 files changed, 11 insertions, 6 deletions
diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs
index c86010379f4..d38a9594d86 100644
--- a/src/bootstrap/test.rs
+++ b/src/bootstrap/test.rs
@@ -975,9 +975,19 @@ impl Step for Compiletest {
             builder.ensure(compile::Rustc { compiler, target });
         }
 
-        if builder.no_std(target) != Some(true) {
+        if builder.no_std(target) == Some(true) {
+            // the `test` doesn't compile for no-std targets
+            builder.ensure(compile::Std { compiler, target });
+        } else {
             builder.ensure(compile::Test { compiler, target });
         }
+
+        if builder.no_std(target) == Some(true) {
+            // for no_std run-make (e.g. thumb*), 
+            // we need a host compiler which is called by cargo.
+            builder.ensure(compile::Std { compiler, target: compiler.host });
+        }
+
         builder.ensure(native::TestHelpers { target });
         builder.ensure(RemoteCopyLibs { compiler, target });
 
diff --git a/src/test/run-make/thumb-none-cortex-m/Makefile b/src/test/run-make/thumb-none-cortex-m/Makefile
index a3540b3a3a9..38f437f150e 100644
--- a/src/test/run-make/thumb-none-cortex-m/Makefile
+++ b/src/test/run-make/thumb-none-cortex-m/Makefile
@@ -11,13 +11,8 @@ TMP_DIR := /tmp/safe_place
 CRATE := cortex-m
 RUSTC := $(RUSTC_ORIGINAL)
 LD_LIBRARY_PATH := $(HOST_RPATH_DIR)
-HOST := x86_64-unknown-linux-gnu
 
 all:
-	# Workaround for error[E0463]: can't find crate for `core`
-	-ln -sv $(SRC)/build/tmp/dist/rust-std-*-$(TARGET)/rust-std-$(TARGET)/lib/rustlib/$(TARGET)/lib/*.rlib $(SRC)/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/$(TARGET)/lib/
-	# Workaround for error[E0463]: can't find crate for `std`
-	-ln -sv $(SRC)/build/tmp/dist/rust-std-*-$(HOST)/rust-std-$(HOST)/lib/rustlib/$(HOST)/lib/*.rlib $(SRC)/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/$(HOST)/lib/
 	env > env.txt
 	mkdir -p $(TMP_DIR)
 	-cd $(TMP_DIR) && rm -rf $(CRATE)