Skip to content

Conversation

cuviper
Copy link
Member

@cuviper cuviper commented Oct 6, 2025

When building with rust.rpath = false, every rustc invocation needs
to include the library path as well. I particularly ran into this in
generate_target_spec_json_schema when testing 1.91-beta in Fedora,
where we do disable rpath for our system builds. The new helper function
will hopefully encourage the right thing going forward.

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Oct 6, 2025
@rustbot
Copy link
Collaborator

rustbot commented Oct 6, 2025

r? @Zalathar

rustbot has assigned @Zalathar.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@cuviper
Copy link
Member Author

cuviper commented Oct 6, 2025

I particularly ran into this [...] when testing 1.91-beta in Fedora,

@rustbot label beta-nominated

@rustbot rustbot added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Oct 6, 2025
@Zalathar
Copy link
Contributor

Zalathar commented Oct 7, 2025

r? bootstrap

@rustbot rustbot assigned Mark-Simulacrum and unassigned Zalathar Oct 7, 2025
@jieyouxu
Copy link
Member

jieyouxu commented Oct 7, 2025

The idea makes sense to me. Want to hear a second opinion on the API and its naming.

When building with `rust.rpath = false`, every `rustc` invocation needs
to include the library path as well. I particularly ran into this in
`generate_target_spec_json_schema` when testing 1.91-beta in Fedora,
where we do disable rpath for our system builds. The new helper function
will hopefully encourage the right thing going forward.
@cuviper cuviper force-pushed the bootstrap-rustc-libs branch from babf9a2 to 03cdcb5 Compare October 7, 2025 16:56
Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have an alternative shape in mind, and this seems very reasonable (esp. with the added comment). Thanks.

View changes since this review

@jieyouxu
Copy link
Member

jieyouxu commented Oct 9, 2025

r? jieyouxu @bors r=Zalathar,jieyouxu rollup

@bors
Copy link
Collaborator

bors commented Oct 9, 2025

📌 Commit 03cdcb5 has been approved by Zalathar,jieyouxu

It is now in the queue for this repository.

@rustbot rustbot assigned jieyouxu and unassigned Mark-Simulacrum Oct 9, 2025
@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 9, 2025
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 9, 2025
…lathar,jieyouxu

bootstrap: add `Builder::rustc_cmd` that includes the lib path

When building with `rust.rpath = false`, every `rustc` invocation needs
to include the library path as well. I particularly ran into this in
`generate_target_spec_json_schema` when testing 1.91-beta in Fedora,
where we do disable rpath for our system builds. The new helper function
will hopefully encourage the right thing going forward.
bors added a commit that referenced this pull request Oct 9, 2025
Rollup of 7 pull requests

Successful merges:

 - #146568 (Port the implemention of SIMD intrinsics from Miri to const-eval)
 - #147373 (give a better example why `std` modules named like primitives are needed)
 - #147419 (bootstrap: add `Builder::rustc_cmd` that includes the lib path)
 - #147457 (specialize slice::fill to use memset when possible)
 - #147468 (Implement fs api set_times and set_times_nofollow)
 - #147489 (Prefer to use repeat_n over repeat().take())
 - #147506 (compiletest: Isolate public APIs and minimize public surface area)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit that referenced this pull request Oct 9, 2025
Rollup of 12 pull requests

Successful merges:

 - #146568 (Port the implemention of SIMD intrinsics from Miri to const-eval)
 - #147373 (give a better example why `std` modules named like primitives are needed)
 - #147419 (bootstrap: add `Builder::rustc_cmd` that includes the lib path)
 - #147420 (Add diagnostic items for `pub mod consts` of FP types)
 - #147457 (specialize slice::fill to use memset when possible)
 - #147467 (Fix double warnings on `#[no_mangle]`)
 - #147470 (Clarify how to remediate the panic_immediate_abort error)
 - #147480 (Do not invalidate CFG caches in CtfeLimit.)
 - #147481 (format: some small cleanup)
 - #147488 (refactor: Remove `LLVMRustInsertPrivateGlobal` and `define_private_global`)
 - #147489 (Prefer to use repeat_n over repeat().take())
 - #147506 (compiletest: Isolate public APIs and minimize public surface area)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 68f9b3b into rust-lang:master Oct 9, 2025
10 checks passed
@rustbot rustbot added this to the 1.92.0 milestone Oct 9, 2025
rust-timer added a commit that referenced this pull request Oct 9, 2025
Rollup merge of #147419 - cuviper:bootstrap-rustc-libs, r=Zalathar,jieyouxu

bootstrap: add `Builder::rustc_cmd` that includes the lib path

When building with `rust.rpath = false`, every `rustc` invocation needs
to include the library path as well. I particularly ran into this in
`generate_target_spec_json_schema` when testing 1.91-beta in Fedora,
where we do disable rpath for our system builds. The new helper function
will hopefully encourage the right thing going forward.
@jieyouxu
Copy link
Member

jieyouxu commented Oct 9, 2025

Voting in #t-infra/bootstrap/backports > #147419: beta-nominated, marking as accepted.

@rustbot label: +beta-accepted

@rustbot rustbot added the beta-accepted Accepted for backporting to the compiler in the beta channel. label Oct 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beta-accepted Accepted for backporting to the compiler in the beta channel. beta-nominated Nominated for backporting to the compiler in the beta channel. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants