Commit 69e8e2d
committed
Auto merge of rust-lang#3411 - RalfJung:sysroot, r=RalfJung
Handle Miri sysroot entirely outside the Miri driver
(Extracted from rust-lang/miri#3409)
This entirely moves the responsibility of setting miri-sysroot to whatever *invokes* the Miri driver. cargo-miri knows whether it is inside rustdoc or not and can adjust accordingly. I previously avoided doing that because there are a bunch of places that are invoking the driver (cargo-miri, the ui test suite, `./miri run`, `./x.py run miri`) and they all need to be adjusted now. But it is also somewhat less fragile as we usually have more information there -- and we can just decide that `./miri run file.rs --sysroot path` is not supported. The advantage of this is that the driver is reasonably clean and doesn't need magic environment variables like MIRI_SYSROOT, and we don't have to fight rustc_driver to use a different default sysroot. Everything is done in cargo-miri (and the other much simpler driver wrappers) where it can hopefully be debugged much better.File tree
5 files changed
+51
-54
lines changed- src/tools/miri
- cargo-miri/src
- miri-script/src
- src/bin
- tests
5 files changed
+51
-54
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
451 | 451 | | |
452 | 452 | | |
453 | 453 | | |
454 | | - | |
| 454 | + | |
| 455 | + | |
455 | 456 | | |
456 | 457 | | |
457 | 458 | | |
458 | 459 | | |
459 | 460 | | |
460 | 461 | | |
461 | | - | |
462 | | - | |
463 | | - | |
464 | | - | |
465 | | - | |
466 | | - | |
467 | | - | |
468 | | - | |
469 | | - | |
470 | | - | |
471 | | - | |
472 | | - | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
473 | 470 | | |
474 | 471 | | |
475 | | - | |
476 | | - | |
477 | | - | |
478 | | - | |
479 | | - | |
480 | | - | |
481 | | - | |
| 472 | + | |
| 473 | + | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
482 | 478 | | |
483 | | - | |
| 479 | + | |
484 | 480 | | |
485 | 481 | | |
486 | 482 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
172 | 172 | | |
173 | 173 | | |
174 | 174 | | |
175 | | - | |
176 | | - | |
177 | 175 | | |
178 | 176 | | |
179 | 177 | | |
| |||
200 | 198 | | |
201 | 199 | | |
202 | 200 | | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
| 201 | + | |
207 | 202 | | |
208 | 203 | | |
209 | 204 | | |
| |||
212 | 207 | | |
213 | 208 | | |
214 | 209 | | |
215 | | - | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
216 | 214 | | |
217 | 215 | | |
218 | 216 | | |
219 | 217 | | |
220 | 218 | | |
221 | 219 | | |
222 | 220 | | |
| 221 | + | |
| 222 | + | |
223 | 223 | | |
224 | 224 | | |
225 | 225 | | |
| |||
412 | 412 | | |
413 | 413 | | |
414 | 414 | | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
415 | 418 | | |
416 | 419 | | |
417 | 420 | | |
| |||
574 | 577 | | |
575 | 578 | | |
576 | 579 | | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
577 | 586 | | |
578 | 587 | | |
579 | 588 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
20 | 21 | | |
21 | 22 | | |
22 | 23 | | |
23 | | - | |
24 | | - | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
25 | 27 | | |
26 | | - | |
| 28 | + | |
27 | 29 | | |
28 | 30 | | |
29 | 31 | | |
| |||
57 | 59 | | |
58 | 60 | | |
59 | 61 | | |
60 | | - | |
61 | | - | |
| 62 | + | |
| 63 | + | |
62 | 64 | | |
63 | 65 | | |
64 | 66 | | |
| |||
505 | 507 | | |
506 | 508 | | |
507 | 509 | | |
508 | | - | |
509 | | - | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
510 | 514 | | |
511 | 515 | | |
512 | 516 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
271 | 271 | | |
272 | 272 | | |
273 | 273 | | |
274 | | - | |
275 | | - | |
276 | | - | |
277 | | - | |
278 | | - | |
279 | | - | |
280 | | - | |
281 | | - | |
282 | | - | |
283 | | - | |
284 | | - | |
285 | | - | |
286 | | - | |
287 | | - | |
288 | | - | |
289 | | - | |
290 | | - | |
291 | | - | |
292 | | - | |
293 | 274 | | |
294 | 275 | | |
295 | 276 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
115 | 122 | | |
116 | 123 | | |
117 | 124 | | |
| |||
0 commit comments