Skip to content

Windows plugin's CMake should have a FLUTTER_TARGET_PLATFORM variable set (like Linux) #116196

@GregoryConrad

Description

@GregoryConrad

Use case

Once Windows ARM is supported (#53120), there will be two supported Windows platforms (windows-x64 and windows-arm64). When making an FFI plugin that uses a unique build process (e.g. Rust), it is necessary to know the target platform to include architecture-specific dynamic libraries (.so/.dll).

Proposal

Add the FLUTTER_TARGET_PLATFORM variable to Windows CMake (just like Linux's right now). Even if it is just a placeholder for windows-x64 for now, it will make migration to Windows ARM easier in the future. For reference, here are the two possible values for FLUTTER_TARGET_PLATFORM on linux right now (afaik):

  • linux-arm64
  • linux-x64

(Which appear to map pretty closely to the Dart ABIs.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projecta: desktopRunning on desktopc: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterplatform-windowsBuilding on or for Windows specificallyr: fixedIssue is closed as already fixed in a newer versionteam-windowsOwned by the Windows platform teamtoolAffects the "flutter" command-line tool. See also t: labels.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions