]> git.lizzy.rs Git - rust.git/commitdiff
Update compiletest.rs
authorOliver Schneider <oli-obk@users.noreply.github.com>
Thu, 10 Aug 2017 17:39:32 +0000 (19:39 +0200)
committerGitHub <noreply@github.com>
Thu, 10 Aug 2017 17:39:32 +0000 (19:39 +0200)
tests/compiletest.rs

index 78886d96413fbdad88caa981bb8e52627bf73580..5ceb60de638a66605c33674742d2953b7c1d72ab 100644 (file)
@@ -73,8 +73,10 @@ fn run_pass(path: &str) {
         config.rustc_path = rustc_path;
         config.run_lib_path = rustc_lib_path();
         config.compile_lib_path = rustc_lib_path();
+        config.target_rustcflags = Some(format!("-Dwarnings --sysroot {}", get_sysroot().display()));
+    } else {
+        config.target_rustcflags = Some("-Dwarnings".to_owned());
     }
-    config.target_rustcflags = Some(format!("-Dwarnings --sysroot {}", get_sysroot().display()));
     config.host_rustcflags = Some("-Dwarnings".to_string());
     compiletest::run_tests(&config);
 }