Skip to content

build,cares,openssl,zlib: limit symbol exports #27664

Description

@bnoordhuis

Refs: #4932 #6274

On Windows, Node exports a curated list of symbols from its dependencies that don't use dllimport/dllexport (c-ares, openssl, zlib)

On Unices, Node indiscriminately re-exports everything thanks to -Wl,--whole-archive.

There's a comment about it in node.gyp:

# TODO(bnoordhuis) Make all platforms export the same list of symbols.
# Teach mkssldef.py to generate linker maps that UNIX linkers understand.

It would be good to implement that. It should help trim down the binary size.

Metadata

Metadata

Assignees

No one assigned

    Labels

    buildIssues and PRs related to Node.js builds or CI infrastructure.opensslIssues and PRs related to the OpenSSL dependency.staleIssues and PRs marked stale due to inactivity and scheduled for automatic closure.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions