From 2c7368702bca9037a14ee5225dd87307e2a8c398 Mon Sep 17 00:00:00 2001 From: Jorge Aparicio Date: Mon, 6 Feb 2017 15:11:09 -0500 Subject: [PATCH] Don't build any native compiler-builtin components for emscripten rust-lang/rust#36339 --- library/compiler-builtins/build.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/library/compiler-builtins/build.rs b/library/compiler-builtins/build.rs index 16c721c6f3a6..6d9801300aab 100644 --- a/library/compiler-builtins/build.rs +++ b/library/compiler-builtins/build.rs @@ -50,6 +50,12 @@ fn main() { println!("cargo:rerun-if-changed=build.rs"); let target = env::var("TARGET").unwrap(); + + // Emscripten's runtime includes all the builtins + if target.contains("emscripten") { + return; + } + let Cfg { ref target_arch, ref target_os, ref target_env, ref target_vendor, .. } = Cfg::new(&target).unwrap_or_else(|e| { writeln!(io::stderr(), "{}", e).ok();