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

Link to libgcc when statically linking musl #1034

Merged
merged 1 commit into from
Jul 9, 2018

Conversation

Amanieu
Copy link
Member

@Amanieu Amanieu commented Jul 6, 2018

On some architectures (e.g. aarch64) musl depends on some libgcc functions (__addtf3, __multf3, __subtf3) for long double arithmetic that it uses internally. Unfortunately we don't provide these functions in compiler-builtins, so we instead need to get them from libgcc.

Fixes:
rust-lang/rust#46651
rust-lang/compiler-builtins#201
rust-lang/compiler-builtins#217

@rust-highfive
Copy link

r? @alexcrichton

(rust_highfive has picked a reviewer for you, use r? to override)

@alexcrichton
Copy link
Member

Could you try bootstrapping rustc with this change to confirm that it works? Once that's working should be good to merge!

Amanieu added a commit to Amanieu/rust that referenced this pull request Jul 8, 2018
@Amanieu
Copy link
Member Author

Amanieu commented Jul 8, 2018

I bootstrapped rustc with the aarch64-unknown-linux-musl target and it fixes the linker errors in the issues mentioned.

There's just a small change required in the CI scripts: rust-lang/rust#52157

@Amanieu
Copy link
Member Author

Amanieu commented Jul 8, 2018

Seems to be a spurious failure on travis? Not sure why this change would cause iOS to fail...

@alexcrichton
Copy link
Member

Ok great! In that case let's merge this and fold it with the rust PR

@bors: r+

@bors
Copy link
Contributor

bors commented Jul 9, 2018

📌 Commit 920cfea has been approved by alexcrichton

@bors
Copy link
Contributor

bors commented Jul 9, 2018

⌛ Testing commit 920cfea with merge 37e3a22...

bors added a commit that referenced this pull request Jul 9, 2018
Link to libgcc when statically linking musl

On some architectures (e.g. aarch64) musl depends on some libgcc functions (`__addtf3`, `__multf3`, `__subtf3`) for `long double` arithmetic that it uses internally. Unfortunately we don't provide these functions in compiler-builtins, so we instead need to get them from libgcc.

Fixes:
rust-lang/rust#46651
rust-lang/compiler-builtins#201
rust-lang/compiler-builtins#217
@bors
Copy link
Contributor

bors commented Jul 9, 2018

☀️ Test successful - status-appveyor, status-travis
Approved by: alexcrichton
Pushing 37e3a22 to master...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants