This directory contains a few build rules imported from an August 2021 snapshot of the Fuchsia GN SDK, with small (required) path adjustments.
The Dart Fuchsia tests require the Fuchsia Core SDK, and the build rules in the GN SDK require slight path modification to support building against the Fuchsia Core SDK from a different location. Therefore, the Fuchsia Core SDK is downloaded via gclient sync
(versioned according to its fingerprint in DEPS), and the modified build rules from Fuchsia GN SDK are, for now, copied to and maintained in flutter/engine.
It is not yet clear if Fuchsia will want to provide SDK resources that support GN build rules with Dart libraries and tests, but if that does happen, these files should be replaced by the Fuchsia-provided build rules.
It may be wise to consider replacing a few other duplicated (but differently built) build rules in //flutter/tools/fuchsia
and //build
with up-to-date (via gclient sync
) rules from the GN SDK. Some of the flutter versions of these rules were originally imported from the fuchsia.git //build
directory, and tailored for flutter. The GN SDK build rules offer simplified versions of these rules, pre-tailored for the Fuchsia SDK layout and out-of-tree use cases.
Known build files in this category, with the same file name and similar GN templates, in both Flutter and Fuchsia GN SDK, include:
Other Flutter GN SDK build rules that could replace flutter implemented logic include:
//flutter/tools/fuchsia/sdk/sdk_targets.gni
and/or //build/fuchsia/sdk.gni
SDK build logic that might improve GN target implementations in flutter include: