Skip to content

Commit eaea98a

Browse files
committed
rustc-dev-guide: remove mentions of legacy Makefile run-make infra
And remove outdated requirements to run `run-make` tests on Windows.
1 parent 9c7239b commit eaea98a

File tree

3 files changed

+2
-58
lines changed

3 files changed

+2
-58
lines changed

src/doc/rustc-dev-guide/src/tests/compiletest.md

+1-29
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,7 @@ The following test suites are available, with links for more information:
7474

7575
### General purpose test suite
7676

77-
[`run-make`](#run-make-tests) are general purpose tests using Rust programs (or
78-
Makefiles (legacy)).
77+
[`run-make`](#run-make-tests) are general purpose tests using Rust programs.
7978

8079
### Rustdoc test suites
8180

@@ -396,14 +395,6 @@ your test, causing separate files to be generated for 32bit and 64bit systems.
396395

397396
### `run-make` tests
398397

399-
> **Note on phasing out `Makefile`s**
400-
>
401-
> We are planning to migrate all existing Makefile-based `run-make` tests
402-
> to Rust programs. You should not be adding new Makefile-based `run-make`
403-
> tests.
404-
>
405-
> See <https://github.com/rust-lang/rust/issues/121876>.
406-
407398
The tests in [`tests/run-make`] are general-purpose tests using Rust *recipes*,
408399
which are small programs (`rmake.rs`) allowing arbitrary Rust code such as
409400
`rustc` invocations, and is supported by a [`run_make_support`] library. Using
@@ -424,11 +415,6 @@ Compiletest directives like `//@ only-<target>` or `//@ ignore-<target>` are
424415
supported in `rmake.rs`, like in UI tests. However, revisions or building
425416
auxiliary via directives are not currently supported.
426417

427-
Two `run-make` tests are ported over to Rust recipes as examples:
428-
429-
- <https://github.com/rust-lang/rust/tree/master/tests/run-make/CURRENT_RUSTC_VERSION>
430-
- <https://github.com/rust-lang/rust/tree/master/tests/run-make/a-b-a-linker-guard>
431-
432418
#### Quickly check if `rmake.rs` tests can be compiled
433419

434420
You can quickly check if `rmake.rs` tests can be compiled without having to
@@ -481,20 +467,6 @@ Then add a corresponding entry to `"rust-analyzer.linkedProjects"`
481467
],
482468
```
483469

484-
#### Using Makefiles (legacy)
485-
486-
<div class="warning">
487-
You should avoid writing new Makefile-based `run-make` tests.
488-
</div>
489-
490-
Each test should be in a separate directory with a `Makefile` indicating the
491-
commands to run.
492-
493-
There is a [`tools.mk`] Makefile which you can include which provides a bunch of
494-
utilities to make it easier to run commands and compare outputs. Take a look at
495-
some of the other tests for some examples on how to get started.
496-
497-
[`tools.mk`]: https://github.com/rust-lang/rust/blob/master/tests/run-make/tools.mk
498470
[`tests/run-make`]: https://github.com/rust-lang/rust/tree/master/tests/run-make
499471
[`run_make_support`]: https://github.com/rust-lang/rust/tree/master/src/tools/run-make-support
500472

src/doc/rustc-dev-guide/src/tests/directives.md

+1-6
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,7 @@
66
FIXME(jieyouxu) completely revise this chapter.
77
-->
88

9-
Directives are special comments that tell compiletest how to build and interpret
10-
a test. They must appear before the Rust source in the test. They may also
11-
appear in `rmake.rs` or legacy Makefiles for [run-make
12-
tests](compiletest.md#run-make-tests).
9+
Directives are special comments that tell compiletest how to build and interpret a test. They must appear before the Rust source in the test. They may also appear in `rmake.rs` [run-make tests](compiletest.md#run-make-tests).
1310

1411
They are normally put after the short comment that explains the point of this
1512
test. Compiletest test suites use `//@` to signal that a comment is a directive.
@@ -218,8 +215,6 @@ The following directives will check LLVM support:
218215
[`aarch64-gnu-debug`]), which only runs a
219216
subset of `run-make` tests. Other tests with this directive will not
220217
run at all, which is usually not what you want.
221-
- Notably, the [`aarch64-gnu-debug`] CI job *currently* only runs `run-make`
222-
tests which additionally contain `clang` in their test name.
223218

224219
See also [Debuginfo tests](compiletest.md#debuginfo-tests) for directives for
225220
ignoring debuggers.

src/doc/rustc-dev-guide/src/tests/running.md

-23
Original file line numberDiff line numberDiff line change
@@ -240,28 +240,6 @@ and they may not run the same without those options.
240240

241241
## Running `run-make` tests
242242

243-
### Windows
244-
245-
Running the `run-make` test suite on Windows is a currently bit more involved.
246-
There are numerous prerequisites and environmental requirements:
247-
248-
- Install msys2: <https://www.msys2.org/>
249-
- Specify `MSYS2_PATH_TYPE=inherit` in `msys2.ini` in the msys2 installation directory, run the
250-
following with `MSYS2 MSYS`:
251-
- `pacman -Syuu`
252-
- `pacman -S make`
253-
- `pacman -S diffutils`
254-
- `pacman -S binutils`
255-
- `./x test run-make` (`./x test tests/run-make` doesn't work)
256-
257-
There is [on-going work][port-run-make] to not rely on `Makefile`s in the
258-
run-make test suite. Once this work is completed, you can run the entire
259-
`run-make` test suite on native Windows inside `cmd` or `PowerShell` without
260-
needing to install and use MSYS2. As of <!--date-check --> Oct 2024, it is
261-
already possible to run the vast majority of the `run-make` test suite outside
262-
of MSYS2, but there will be failures for the tests that still use `Makefile`s
263-
due to not finding `make`.
264-
265243
## Running tests on a remote machine
266244

267245
Tests may be run on a remote machine (e.g. to test builds for a different
@@ -406,4 +384,3 @@ If you encounter bugs or problems, don't hesitate to open issues on the
406384
repository](https://github.com/rust-lang/rustc_codegen_gcc/).
407385

408386
[`tests/ui`]: https://github.com/rust-lang/rust/tree/master/tests/ui
409-
[port-run-make]: https://github.com/rust-lang/rust/issues/121876

0 commit comments

Comments
 (0)