Commit 5cc1baa
committed
Auto merge of #43482 - Mark-Simulacrum:single-rustdoc, r=alexcrichton
Compile rustdoc on-demand
Fixes #43284, fixes #38318, and fixes #39505.
Doesn't directly help with #42686, since we need to rebuild just as much. In fact, this hurts it, since `./x.py doc --stage 0` will now fail. I'm not sure if it did before, but with these changes it runs into the problem where we attempt to use artifacts from bootstrap rustc with a non-bootstrap rustdoc, running into version conflicts. I believe this is solvable, but leaving for a future PR.
This means that rustdoc will no longer be compiled when compiling rustc, by default. However, it is still built from `./x.py build` (for hosts, but not targets, since we don't produce compiler toolchains for them) and will be built for doc tests and crate tests.
After this, the recommended workflow if you want a rustdoc is: `./x.py build --stage 1 src/tools/rustdoc` which will give you a working rustdoc in `build/triple/stage1/bin/rustdoc`. Note that you can add `src/libstd` onto the command to compile libstd as well so that the rustdoc can easily compile crates in the wild. `./x.py doc --stage 1 src/libstd` will document `libstd` with a freshly built rustdoc (if necessary), and will not rebuild rustc on modifications to rustdoc.
r? @alexcrichtonFile tree
18 files changed
+181
-144
lines changed- src
- bootstrap
- driver
- librustdoc
- rustc
- tools
- compiletest/src
- error_index_generator
- rustdoc
18 files changed
+181
-144
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
256 | 256 | | |
257 | 257 | | |
258 | 258 | | |
259 | | - | |
| 259 | + | |
260 | 260 | | |
261 | 261 | | |
262 | 262 | | |
| |||
412 | 412 | | |
413 | 413 | | |
414 | 414 | | |
415 | | - | |
416 | 415 | | |
417 | | - | |
418 | | - | |
419 | | - | |
420 | | - | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
421 | 432 | | |
422 | 433 | | |
423 | 434 | | |
| |||
469 | 480 | | |
470 | 481 | | |
471 | 482 | | |
472 | | - | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
473 | 488 | | |
474 | 489 | | |
475 | 490 | | |
| |||
560 | 575 | | |
561 | 576 | | |
562 | 577 | | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
563 | 581 | | |
564 | 582 | | |
565 | 583 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
122 | | - | |
| 122 | + | |
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
| |||
140 | 140 | | |
141 | 141 | | |
142 | 142 | | |
143 | | - | |
| 143 | + | |
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
| |||
194 | 194 | | |
195 | 195 | | |
196 | 196 | | |
197 | | - | |
| 197 | + | |
198 | 198 | | |
199 | 199 | | |
200 | 200 | | |
| |||
240 | 240 | | |
241 | 241 | | |
242 | 242 | | |
243 | | - | |
| 243 | + | |
244 | 244 | | |
245 | 245 | | |
246 | 246 | | |
| |||
562 | 562 | | |
563 | 563 | | |
564 | 564 | | |
565 | | - | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
566 | 571 | | |
567 | 572 | | |
568 | 573 | | |
| |||
809 | 814 | | |
810 | 815 | | |
811 | 816 | | |
812 | | - | |
813 | | - | |
| 817 | + | |
814 | 818 | | |
815 | 819 | | |
816 | 820 | | |
| |||
1165 | 1169 | | |
1166 | 1170 | | |
1167 | 1171 | | |
1168 | | - | |
| 1172 | + | |
1169 | 1173 | | |
1170 | 1174 | | |
1171 | 1175 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
719 | 719 | | |
720 | 720 | | |
721 | 721 | | |
722 | | - | |
723 | | - | |
724 | | - | |
725 | | - | |
726 | | - | |
727 | | - | |
728 | | - | |
729 | | - | |
730 | | - | |
731 | 722 | | |
732 | 723 | | |
733 | 724 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
413 | 413 | | |
414 | 414 | | |
415 | 415 | | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
416 | 419 | | |
417 | 420 | | |
418 | 421 | | |
| |||
963 | 966 | | |
964 | 967 | | |
965 | 968 | | |
966 | | - | |
| 969 | + | |
| 970 | + | |
| 971 | + | |
| 972 | + | |
967 | 973 | | |
968 | 974 | | |
969 | 975 | | |
| |||
1046 | 1052 | | |
1047 | 1053 | | |
1048 | 1054 | | |
1049 | | - | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
| 1058 | + | |
1050 | 1059 | | |
1051 | 1060 | | |
1052 | 1061 | | |
| |||
0 commit comments