Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

download-rustc has no effect when running run-make tests #131947

Closed
Tracked by #131744
lolbinarycat opened this issue Oct 19, 2024 · 8 comments
Closed
Tracked by #131744

download-rustc has no effect when running run-make tests #131947

lolbinarycat opened this issue Oct 19, 2024 · 8 comments
Labels
A-run-make Area: port run-make Makefiles to rmake.rs C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@lolbinarycat
Copy link
Contributor

reproduction steps:

  1. set rust.download-rustc = true in config.toml
  2. run ./x test --stage 1 tests/run-make

expected behavior: rustc is downloaded

actually behavior: rustc and cargo are built from source

@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Oct 19, 2024
@Noratrieb
Copy link
Member

Why do you want to run tests on the downloaded compiler?

@jieyouxu
Copy link
Member

jieyouxu commented Oct 20, 2024

I don't quite understand this use case. COMPILETEST_FORCE_STAGE0=1 ./x test --stage 0 tests/run-make will run tests on a downloaded beta compiler, or otherwise a user-provided initial rustc (such as a previous stage2 compiler as part of opt-dist step). Running the tests on a beta compiler or an initial rustc that is older is not a supported use case in the general sense. Many run-make tests will fail. Having download-rustc = true mean the stage 1 rustc also getting downloaded makes no sense to me, you'll just run into the same test failures when you try to run the run-make tests with the aforementioned beta compiler.

Could you elaborate why you want this, or what this is in the context of?

@jieyouxu jieyouxu added C-discussion Category: Discussion or questions that doesn't represent real issues. and removed needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. labels Oct 20, 2024
@bjorn3
Copy link
Member

bjorn3 commented Oct 20, 2024

If you only modified the standard library and want to run run-make tests to see if your change broke something, I would expect download-rustc be enough to avoid having to recompile the compiler itself. There is no need to recompile the compiler in that case as it wasn't modified.

@jieyouxu
Copy link
Member

I see

@jieyouxu jieyouxu added T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) C-bug Category: This is a bug. A-run-make Area: port run-make Makefiles to rmake.rs and removed C-discussion Category: Discussion or questions that doesn't represent real issues. labels Oct 20, 2024
@lolbinarycat
Copy link
Contributor Author

Why do you want to run tests on the downloaded compiler?

in my case, i was trying to modify compiletest, but it also would be useful if you're modifying the tests themselves.

@jieyouxu
Copy link
Member

in my case, i was trying to modify compiletest

For compiletest specifically, compiletest is a stage0 bootstrap tool, so you can just ./x test src/tools/compiletest --stage 0 to make it build (and run its unit tests). But yes, it could be helpful to have download-rustc working with the test suite as well.

@onur-ozkan
Copy link
Member

Added to Tracking Issue for download-rustc improvements.

@onur-ozkan
Copy link
Member

Fixed with #132006.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-run-make Area: port run-make Makefiles to rmake.rs C-bug Category: This is a bug. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

No branches or pull requests

6 participants