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

bootstrap: Rename profile = user to profile = dist #112074

Closed
jyn514 opened this issue May 29, 2023 · 7 comments · Fixed by #112166 or #113068
Closed

bootstrap: Rename profile = user to profile = dist #112074

jyn514 opened this issue May 29, 2023 · 7 comments · Fixed by #112166 or #113068
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-help-wanted Call for participation: Help is requested to fix this issue. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@jyn514
Copy link
Member

jyn514 commented May 29, 2023

config.user.toml currently says:

# These defaults are meant for users and distro maintainers building from source, without intending to make multiple changes.

"users" is so ambiguous as to be meaningless. What I originally intended was something like "people building from source once and installing it locally", like Gentoo users or something. I think "dist" is a much better name for this profile: it makes it more clear why CI uses the profile and it hopefully will make it easier for distros to find and understand.

cc @cuviper - you said in https://rust-lang.zulipchat.com/#narrow/stream/233931-t-compiler.2Fmajor-changes/topic/Redesign.20bootstrap.20stages.20compiler-team.23619/near/351408631 this would be helpful, do you still think that? The only other name I can think of is something like install but I'm not sure that's a good description of what CI is doing with the profile.

@jyn514 jyn514 added the T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) label May 29, 2023
@jyn514
Copy link
Member Author

jyn514 commented May 29, 2023

Mentoring instructions: I want to do this in a backwards compatible way, so that old config files keep working seamlessly. To do this you'll need to add a way to add aliases to profiles. Take a look around

rust/src/bootstrap/config.rs

Lines 994 to 1002 in 5e2969e

if let Some(include) = &toml.profile {
let mut include_path = config.src.clone();
include_path.push("src");
include_path.push("bootstrap");
include_path.push("defaults");
include_path.push(format!("config.{}.toml", include));
let included_toml = get_toml(&include_path);
toml.merge(included_toml);
}
and change it to treat user the same as dist. Then rename the relevant places around
Please add a test in src/bootstrap/config/tests.rs once you're done.

@jyn514 jyn514 added E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-help-wanted Call for participation: Help is requested to fix this issue. labels May 29, 2023
Swarnlataaa added a commit to Swarnlataaa/rust that referenced this issue May 29, 2023
@ghost
Copy link

ghost commented May 31, 2023

@jyn514 can i work on this

@jyn514
Copy link
Member Author

jyn514 commented May 31, 2023

@AnakinSkywalkeer you should talk to @Swarnlataaa - they have #112078 open but it's broken, I'm not sure of the status.

@ghost
Copy link

ghost commented May 31, 2023

@AnakinSkywalkeer you should talk to @Swarnlataaa - they have #112078 open but it's broken, I'm not sure of the status.

oh okay

@ghost
Copy link

ghost commented Jun 1, 2023

@rustbot claim

@jyn514
Copy link
Member Author

jyn514 commented Jun 3, 2023

this wasn't done properly #112166 (comment)

@jyn514 jyn514 reopened this Jun 3, 2023
@zephaniahong
Copy link
Contributor

@AnakinSkywalkeer Hi! Are you planning to continue working on this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-help-wanted Call for participation: Help is requested to fix this issue. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
2 participants