-
Notifications
You must be signed in to change notification settings - Fork 13.8k
Open
Labels
C-bugCategory: This is a bug.Category: This is a bug.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)needs-triageThis issue may need triage. Remove it if it has been sufficiently triaged.This issue may need triage. Remove it if it has been sufficiently triaged.
Description
Summary
Posted by @denizsokmen #141375 (comment):
Custom target issue is actually more related to Rust bootstrap forcefully cross-compiling crtbegin, crtend and llvm-libunwind for musl for self-contained linkage reasons:
and https://github.com/rust-lang/rust/blob/master/src/bootstrap/src/core/config/target_selection.rs#L96
let libunwind_path = copy_llvm_libunwind(builder, target, &libdir_self_contained); I see no way to opt out of that, even though those binaries won't be used as they'll be fetched from the sysroot of that musl-based custom target. Is there a way to tell Rust bootstrap not to bother with preparing self-contained binaries?
Expected behaviour
A way to out-put crtbegin, crtend and llvm-libunwind build for custom musl target.
Actual behaviour
You'll need to patch code as described: #141375 (comment).
Possible solution
Probalby extend the target
table in bootstrap.toml
like target.self-contained = <bool>
?
Bootstrap configuration (bootstrap.toml)
[target.my-custom-musl]
linker = "…"
musl-root = "…"
cc = "…"
cxx = "…"
cflags = "…"
cxxflags = "…"
rustflags= "…"
llvm-libunwind = "system"
HEAD
Metadata
Metadata
Assignees
Labels
C-bugCategory: This is a bug.Category: This is a bug.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)needs-triageThis issue may need triage. Remove it if it has been sufficiently triaged.This issue may need triage. Remove it if it has been sufficiently triaged.