Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit d332ec1

Browse files
committed
Fixes BUILD.gn if is_fuchsia (legacy embedder) and is_debug
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.
1 parent ccaae8d commit d332ec1

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

BUILD.gn

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,18 @@ config("config") {
2121
}
2222
}
2323

24+
defines = []
25+
2426
# This define is transitional and will be removed after the embedder API
2527
# transition is complete.
2628
#
2729
# TODO(bugs.fuchsia.dev/54041): Remove when no longer necessary.
2830
if (is_fuchsia && flutter_enable_legacy_fuchsia_embedder) {
29-
defines = [ "LEGACY_FUCHSIA_EMBEDDER" ]
31+
defines += [ "LEGACY_FUCHSIA_EMBEDDER" ]
3032
}
3133

3234
if (is_debug) {
33-
defines = [ "FLUTTER_ENABLE_DIFF_CONTEXT" ]
35+
defines += [ "FLUTTER_ENABLE_DIFF_CONTEXT" ]
3436
}
3537
}
3638

0 commit comments

Comments
 (0)