about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2019-09-03 04:33:08 +0000
committerbors <bors@rust-lang.org>2019-09-03 04:33:08 +0000
commit815dec9db156284b4f57a4ec34182ffc89218242 (patch)
treea0801ba58fb379c31a17ede45a08cf33c6e0553f
parentb50520835f3b14409797139eca23f401a529e711 (diff)
parenta80ab3a2f85240ec2f9bda00f7cae1abc50865ef (diff)
downloadrust-815dec9db156284b4f57a4ec34182ffc89218242.tar.gz
rust-815dec9db156284b4f57a4ec34182ffc89218242.zip
Auto merge of #63869 - GuillaumeGomez:fix-build-failure, r=Mark-Simulacrum
Fix build failure in case file doesn't exist

It fixes the following issue:

```bash
$ ./x.py test src/tools/linkchecker ./build/x86_64-apple-darwin/doc/ --stage 1
Updating only changed submodules
Submodules updated in 0.05 seconds
    Finished dev [unoptimized] target(s) in 0.15s
thread 'main' panicked at 'source "/Users/imperio/rust/rust/build/x86_64-apple-darwin/doc/version_info.html" failed to get metadata: No such file or directory (os error 2)', src/build_helper/lib.rs:179:19
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
failed to run: /Users/imperio/rust/rust/build/bootstrap/debug/bootstrap test src/tools/linkchecker ./build/x86_64-apple-darwin/doc/ --stage 1
Build completed unsuccessfully in 0:00:01
```

If the file doesn't exist, it makes sense anyway to just run the command in order to generate it.

r? @Mark-Simulacrum
-rw-r--r--src/bootstrap/doc.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bootstrap/doc.rs b/src/bootstrap/doc.rs
index 3d0a175e820..6faedc80ad3 100644
--- a/src/bootstrap/doc.rs
+++ b/src/bootstrap/doc.rs
@@ -375,7 +375,7 @@ impl Step for Standalone {
                up_to_date(&footer, &html) &&
                up_to_date(&favicon, &html) &&
                up_to_date(&full_toc, &html) &&
-               up_to_date(&version_info, &html) &&
+               (builder.config.dry_run || up_to_date(&version_info, &html)) &&
                (builder.config.dry_run || up_to_date(&rustdoc, &html)) {
                 continue
             }