Closed
Description
executing zig targets
on alpine linux shows:
...
C ABIs:
none
gnu (native)
gnuabin32
gnuabi64
...
Instead it should detect that musl is the native C ABI on alpine linux.
Here are my ideas for detecting this:
- Zig should look at its own dynamic linker. This will determine which C ABI is native.
- If Zig is statically linked, then it should look at the dynamic linker of
/usr/bin/env
. - If there is a problem accessing
/usr/bin/env
or determining its dynamic linker, Zig should conclude that the native C ABI is musl.
This only matters really if you use --library c
and in this case you can work around it with -target x86_64-linux-musl
.