Skip to content

Can we build release binaries with static libc? #142

@ouillie

Description

@ouillie

The pre-built binary targets use dynamic glibc (e.g. x86_64-unknown-linux-gnu), but they could also be compiled with statically-linked musl libc (e.g. x86_64-unknown-linux-musl). I just tried doing this locally for v0.6.0 and it worked without modifying any source code. Furthermore, I was surprised to learn that the musl version is actually slightly smaller than the glibc version (21MB vs 22MB) despite having nothing in the dynamic symbol table (verified with objdump -T).

Would anybody be opposed to switching over to statically-linked pre-built binaries like this? This ought to strictly improve compatibility, which is pretty important for pre-built binaries. I was running into issues trying to use the pre-built binaries in Bazel's CI pipeline.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions