diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs index be62ce3bf3a..4db522ebd13 100644 --- a/src/bootstrap/builder.rs +++ b/src/bootstrap/builder.rs @@ -445,7 +445,8 @@ impl<'a> Builder<'a> { let out_dir = self.stage_out(compiler, mode); cargo.env("CARGO_TARGET_DIR", out_dir) .arg(cmd) - .arg("--target").arg(target); + .arg("--target") + .arg(target); // If we were invoked from `make` then that's already got a jobserver // set up for us so no need to tell Cargo about jobs all over again. diff --git a/src/bootstrap/check.rs b/src/bootstrap/check.rs index 265e7721a97..bfc0009fcfb 100644 --- a/src/bootstrap/check.rs +++ b/src/bootstrap/check.rs @@ -427,6 +427,7 @@ fn path_for_cargo(builder: &Builder, compiler: Compiler) -> OsString { #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub struct RustdocJS { pub host: Interned, + pub target: Interned, } impl Step for RustdocJS { @@ -435,12 +436,13 @@ impl Step for RustdocJS { const ONLY_HOSTS: bool = true; fn should_run(run: ShouldRun) -> ShouldRun { - run.path("src/tests/rustdoc-js") + run.path("src/test/rustdoc-js") } fn make_run(run: RunConfig) { run.builder.ensure(RustdocJS { host: run.host, + target: run.target, }); } @@ -448,6 +450,10 @@ impl Step for RustdocJS { let nodejs = builder.config.nodejs.clone(); let mut command = Command::new(&nodejs.expect("no nodejs found")); command.args(&["src/tools/rustdoc-js/tester.js", &*self.host]); + builder.ensure(::doc::Std { + target: self.target, + stage: builder.top_stage, + }); builder.run(&mut command); } } diff --git a/src/bootstrap/doc.rs b/src/bootstrap/doc.rs index 832da24c994..0930bc15de1 100644 --- a/src/bootstrap/doc.rs +++ b/src/bootstrap/doc.rs @@ -418,8 +418,8 @@ impl Step for Standalone { #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] pub struct Std { - stage: u32, - target: Interned, + pub stage: u32, + pub target: Interned, } impl Step for Std { diff --git a/src/bootstrap/tool.rs b/src/bootstrap/tool.rs index 96947800d44..ea055cb5d1b 100644 --- a/src/bootstrap/tool.rs +++ b/src/bootstrap/tool.rs @@ -260,7 +260,6 @@ tool!( BuildManifest, "src/tools/build-manifest", "build-manifest", Mode::Libstd; RemoteTestClient, "src/tools/remote-test-client", "remote-test-client", Mode::Libstd; RustInstaller, "src/tools/rust-installer", "fabricate", Mode::Libstd; - RustdocJS, "rustdoc-js", "js-tests", Mode::Tool; ); #[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]