]> git.lizzy.rs Git - rust.git/commitdiff
Remove std/test documentation from compiler docs.
authorDavid Wood <david@davidtw.co>
Thu, 22 Mar 2018 20:49:05 +0000 (20:49 +0000)
committerDavid Wood <david@davidtw.co>
Thu, 22 Mar 2018 20:49:05 +0000 (20:49 +0000)
src/bootstrap/dist.rs
src/bootstrap/doc.rs

index e25a7e185258653306f124168c33d8e78ebcb85e..5563b153f5affb5b3133078404b3a38a325a6dea 100644 (file)
@@ -163,7 +163,7 @@ fn run(self, builder: &Builder) -> PathBuf {
         let image = tmpdir(build).join(format!("{}-{}-image", name, host));
         let _ = fs::remove_dir_all(&image);
 
-        let dst = image.join("share/doc/rustc/html");
+        let dst = image.join("share/doc/rust/html");
         t!(fs::create_dir_all(&dst));
         let src = build.compiler_doc_out(host);
         cp_r(&src, &dst);
@@ -179,7 +179,7 @@ fn run(self, builder: &Builder) -> PathBuf {
            .arg(format!("--package-name={}-{}", name, host))
            .arg("--component-name=rustc-docs")
            .arg("--legacy-manifest-dirs=rustlib,cargo")
-           .arg("--bulk-dirs=share/doc/rustc/html");
+           .arg("--bulk-dirs=share/doc/rust/html");
         build.run(&mut cmd);
         t!(fs::remove_dir_all(&image));
 
index e525bdb98fc0c7e0517843439d1c9fd113e9bc15..44073a5b0757237bda2fe96abb1aa873e6432756 100644 (file)
@@ -690,17 +690,10 @@ fn run(self, builder: &Builder) {
         builder.ensure(compile::Rustc { compiler, target });
         let out_dir = build.stage_out(compiler, Mode::Librustc)
                            .join(target).join("doc");
-
-        // See docs in std above for why we symlink
-        //
-        // This step must happen after other documentation steps. This
-        // invariant ensures that compiler documentation is not included
-        // in the standard documentation tarballs but that all the
-        // documentation from the standard documentation tarballs is included
-        // in the compiler documentation tarball.
-        let my_out = build.crate_doc_out(target);
-        build.clear_if_dirty(&my_out, &rustdoc);
-        t!(symlink_dir_force(&my_out, &out_dir));
+        // We do not symlink to the same shared folder that already contains std library
+        // documentation from previous steps as we do not want to include that.
+        build.clear_if_dirty(&out, &rustdoc);
+        t!(symlink_dir_force(&out, &out_dir));
 
         let mut cargo = builder.cargo(compiler, Mode::Librustc, target, "doc");
         compile::rustc_cargo(build, &mut cargo);
@@ -720,7 +713,6 @@ fn run(self, builder: &Builder) {
         }
 
         build.run(&mut cargo);
-        cp_r(&my_out, &out);
     }
 }