-
Notifications
You must be signed in to change notification settings - Fork 13.8k
Closed
Labels
E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Description
x setup
takes a short list of paths determined at runtime. Currently, it's special-cased in bootstrap rather than going through Step::should_run
. But there's no need to special-case it - it can do the run time check in should_run
instead, there's no sandbox. Switching it to should_run
also has the advantage of automatically fixing x setup -h -v
.
The list of paths is "all toml files in src/bootstrap/defaults
".
Mentoring instructions:
- Add
impl Step for Profile
insrc/bootstrap/setup.rs
- Remove the special-casing for
Subcommand::Setup
inBuilder::new
andBuilder::get_step_descriptions
.
cc @aswild - are you interested in tackling this after #96003?
@rustbot label +A-rustbuild +E-easy +E-medium
cc #96003 (comment)
Metadata
Metadata
Assignees
Labels
E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Type
Projects
Milestone
Relationships
Development
Select code repository
Activity
jyn514 commentedon Apr 14, 2022
@rustbot label -E-medium +E-mentor
lameferret commentedon Apr 15, 2022
@rustbot claim
lameferret commentedon Apr 15, 2022
@jyn514 can I get some more details please, as
Profile
is a lot different from the likes of docs.rs, native.rs, etc, and I can't figure it out looking at them.Also, how to run tests for
/bootstrap
?jyn514 commentedon Apr 15, 2022
Hi @anuvratsingh, I left some suggestions on https://rust-lang.zulipchat.com/#narrow/stream/122652-new-members/topic/impl.20Step.20for.20Profile :)
lameferret commentedon Apr 23, 2022
Wasn't able to resolve this, but here are some resources shared by jyn514
bentongxyz commentedon Apr 24, 2022
HI, is it okay if I try to work on this?
@rustbot claim
bentongxyz commentedon Apr 28, 2022
Hi @jyn514, I would like to ask you a few questions, hope you don't mind! I'll be very succinct.
Right now, I managed to
impl Step for Profile
, so that if i run./x.py setup -h -v
, it prints:The paths under 'Available paths:' are dynamically generated by getting all
toml
files under 'defaults' folder.However, I have trouble proceeding because the
setup
subcommand's current behaviour actually does not take a path. Instead, it takes a profile name, such aslibrary
. I quote the help section:i.e. If I run
./x.py setup src/bootstrap/defaults/config.library.toml
, it will return an error.So, should I change the current behaviour so that it accepts a path, e.g.
src/bootstrap/defaults/config.library.toml
?This would involve changes to, amongst other things,
setup
subcommand takingpaths: Vec<PathBuf>
instead ofprofile: Profile
here in flag.rs line 137;I hope I did not misunderstood something!
P.S. I'd be happy to chat with you in rust zulipchat if you'd prefer.
6 remaining items