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

Build musl dist artifacts with debuginfo enabled #90733

Merged
merged 1 commit into from
Nov 17, 2021

Commits on Nov 13, 2021

  1. Build musl dist artifacts with debuginfo enabled

    Since our musl targets link to a version of musl we build and bundle
    with the targets, if users need to debug into musl or generate
    backtraces which contain parts of the musl library, they will be unable
    to do so unless we enable and ship the debug info.
    
    This patch changes our dist builds so they enabled debug info when
    building musl. This patch also includes a fix for CFI detection in
    musl's `configure` script which has been posted upstream[1].
    
    The net effect of this is that we now ship debug info for musl in those
    targets. This adds ~90kb to those artifacts but running `strip` on
    binaries produced removes all of that. For a "hello world" Rust binary
    on x86_64, the numbers are:
    
    |                        | debug | release | release + strip |
    |           -            |   -   |    -    |        -        |
    | without musl debuginfo | 507kb |  495kb  |      410kb      |
    | with musl debuginfo    | 595kb |  584kb  |      410kb      |
    
    Once stripped, the final binaries are the same size (down to the byte).
    
    [1]: https://www.openwall.com/lists/musl/2021/10/21/2
    wesleywiser committed Nov 13, 2021
    Configuration menu
    Copy the full SHA
    e97317c View commit details
    Browse the repository at this point in the history