Skip to content

Add platform constraints for extensions #46633

Description

@phlax

currently we have no way of gating an extension for or from particular platforms

instead we have historically used an anti-pattern of gating with selects rendering empty files/libs on non-compatible platforms

this is an anti-pattern for several reasons

firstly gating only with selects and not proper platform constraints means whatever deps are referenced are pulled in regardless of compatibility

secondly this leaves useless stub bloat in the final bins with extensions that can never run

and finally anything that is properly platform constrained can break unrelated builds if it is not itself properly gated out

realistically the seam here is at the extension level - some extensions - eg socketmap will only ever run on linux - they sshould be gated as such and not included in binaries for other platforms

gating at the extension level would also mean we can document the extensions properly - exposing their actual platform constraints

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions