FS#78698 - [rust-musl] rust 1.70.0 breaks compiling with musl

Attached to Project: Arch Linux
Opened by Adam Fontenot (amfontenot) - Saturday, 03 June 2023, 23:41 GMT
Last edited by kpcyrd (kpcyrd) - Thursday, 31 August 2023, 12:21 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Jan Alexander Steffens (heftig)
Johannes Löthberg (demize)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:

Trying to compile any package with `--target x86_64-unknown-linux-musl` fails after upgrading to 1.70.0; the same packages succeed with 1.69.0.

The failure is in the linking stage: I see linking errors like

/rustc/90c541806f23a127002de5b4038be731ba1458ca/library/std/src/sys/unix/fs.rs:1056: undefined reference to `fstat64'

Steps to reproduce:

cargo new musltest
cd musltest
cargo build --target x86_64-unknown-linux-musl
This task depends upon

Closed by  kpcyrd (kpcyrd)
Thursday, 31 August 2023, 12:21 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in 1:1.72.0-1
Comment by Adam Fontenot (amfontenot) - Sunday, 04 June 2023, 00:50 GMT
I believe this will be fixed by a Rust release containing this PR: https://github.com/rust-lang/libc/pull/2935

Maybe this is a backport candidate for Arch?
Comment by Jan Alexander Steffens (heftig) - Monday, 05 June 2023, 15:42 GMT
That's not enough. There are more users of the LFS64 symbols, in rustc itself and other crates (e.g. random).

Following Gentoo ( https://github.com/gentoo/gentoo/pull/31205 ) we would need at least https://github.com/rust-random/getrandom/pull/326 and https://github.com/rust-lang/rust/pull/106246 as well. However, the latter is unmerged and the author "needs to find time to rework this".
Comment by Toolybird (Toolybird) - Sunday, 09 July 2023, 07:11 GMT
Dupe containing more info  FS#79002 
Comment by kpcyrd (kpcyrd) - Friday, 14 July 2023, 23:56 GMT
For documentation sake, I've tested and and this bug is still present in rust-musl 1:1.71.0-1.

Since 1.71.0 Rust upstream now ships with musl 1.2.3 but not 1.2.4 yet.

Loading...