Fixes BUILD.gn if is_fuchsia (legacy embedder) and is_debug (flutter/engine#25858)

Current recommended build methods may not trigger this issue, but
while trying different options, building flutter for the first time, I
noticed a build error because `defines` was assigned twice.

If building with both options is ever supported, I think this
fixes the error.
This commit is contained in:
Rich Kadel
2021-05-07 10:57:33 -07:00
committed by GitHub
parent 1e82ae9b8e
commit ec987a9868

View File

@@ -21,16 +21,18 @@ config("config") {
}
}
defines = []
# This define is transitional and will be removed after the embedder API
# transition is complete.
#
# TODO(bugs.fuchsia.dev/54041): Remove when no longer necessary.
if (is_fuchsia && flutter_enable_legacy_fuchsia_embedder) {
defines = [ "LEGACY_FUCHSIA_EMBEDDER" ]
defines += [ "LEGACY_FUCHSIA_EMBEDDER" ]
}
if (is_debug) {
defines = [ "FLUTTER_ENABLE_DIFF_CONTEXT" ]
defines += [ "FLUTTER_ENABLE_DIFF_CONTEXT" ]
}
}