8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5eba141 commit 706fc55Copy full SHA for 706fc55
src/bootstrap/sanity.rs
@@ -159,6 +159,13 @@ pub fn check(build: &mut Build) {
159
160
// Make sure musl-root is valid
161
if target.contains("musl") {
162
+ // If this is a native target (host is also musl) and no musl-root is given,
163
+ // fall back to the system toolchain in /usr before giving up
164
+ if build.musl_root(target).is_none() && build.config.build == *target {
165
+ let target = build.config.target_config.entry(target.clone())
166
+ .or_insert(Default::default());
167
+ target.musl_root = Some("/usr".into());
168
+ }
169
match build.musl_root(target) {
170
Some(root) => {
171
if fs::metadata(root.join("lib/libc.a")).is_err() {
0 commit comments