diff --git a/shell/platform/windows/BUILD.gn b/shell/platform/windows/BUILD.gn index 24b506abefd99..9a98e3d814542 100644 --- a/shell/platform/windows/BUILD.gn +++ b/shell/platform/windows/BUILD.gn @@ -74,8 +74,6 @@ source_set("flutter_windows_source") { "keyboard_key_handler.h", "platform_handler.cc", "platform_handler.h", - "string_conversion.cc", - "string_conversion.h", "system_utils.h", "task_runner.h", "text_input_plugin.cc", @@ -152,6 +150,8 @@ source_set("flutter_windows_source") { defines = [ "FLUTTER_ENGINE_NO_PROTOTYPES" ] } + public_deps = [ ":string_conversion" ] + deps = [ ":flutter_windows_headers", "//flutter/shell/platform/common:common_cpp", @@ -171,6 +171,19 @@ source_set("flutter_windows_source") { ] } +# String encoding conversion utilities. +source_set("string_conversion") { + sources = [ + "string_conversion.cc", + "string_conversion.h", + ] + + if (target_os == "winuwp") { + configs += [ ":cppwinrt_defs" ] + cflags = [ "/EHsc" ] + } +} + copy("publish_headers_windows") { sources = _public_headers outputs = [ "$root_out_dir/{{source_file_part}}" ]