stdarch icon indicating copy to clipboard operation
stdarch copied to clipboard

Stdarch support for `wasm32-wali-linux-musl` Tier-3 Linux target

Open arjunr2 opened this issue 11 months ago • 6 comments

To support the new Tier-3 target wasm32-wali-linux-musl within the rust compiler : rust-lang/rust#135651

Minimally, this just disables dynamic-linking related Linux features which is not supported yet in Wasm.

arjunr2 avatar Jan 17 '25 20:01 arjunr2

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @Amanieu (or someone else) some time within the next two weeks.

rustbot avatar Jan 17 '25 20:01 rustbot

Please rebase

sayantn avatar Jan 18 '25 18:01 sayantn

Is there a reason wali doesn't provide getauxvval?

bjorn3 avatar Jan 18 '25 19:01 bjorn3

Is there a reason wali doesn't provide getauxvval?

Wasm doesn't have a dynamic linking specification yet. These features can be added back in the future once supported

arjunr2 avatar Jan 18 '25 19:01 arjunr2

Directly linking to getauxval rather than using dlsym should work if libc for wali is guaranteed to support it, right? The only reason std_detect is using dlsym is because older libc versions for some targets don't support getauxval.

bjorn3 avatar Jan 18 '25 19:01 bjorn3

That's true, we could probably just disable std_detect_dlsym_getauxval when building stdarch for rustc. That should work right?

WALI libc does expose getauxval but support for it is not fully specified/handled yet (particularly architecture-specific types/values) As such, preventing it from being called for the time being is preferable.

arjunr2 avatar Jan 18 '25 20:01 arjunr2