Skip to content

Trim unreachable bundled shared libraries? #129

@quinnj

Description

@quinnj

Similar in some respects to #62, but I noticed post-trimming, I still had some large shared libraries hanging around like libopenblas, libgfortran, etc. that I'm confident aren't reachable from my executable entrypoints. I poked around a bit, but realize it might be tricky to get this all the way right, because we have ccall, lazy library loading, Libdl.dlopen, then shared library dependencies. I tried just allowing a compiler flag to manually prune libraries and that seems to work ok, but requires a bit of trial and error because it turns out libmpfr and libopenlibm have mechanical requirements from Base, even though my own code entrypoints never touch BigFloat or other libm stuff (Base does some libm library name setting thing that forces the library load?)

Anyway, just putting this out there in terms of the goal of "I'd like my final executable bundle to be as small as possible".

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions