| Index: ui/resources/BUILD.gn
|
| diff --git a/ui/resources/BUILD.gn b/ui/resources/BUILD.gn
|
| index 3f7a0df78cd84abf9b9d7a79352518df928d727c..2b75d53b6a97f1e80792404f9ce9fdb6d9910268 100644
|
| --- a/ui/resources/BUILD.gn
|
| +++ b/ui/resources/BUILD.gn
|
| @@ -52,16 +52,14 @@ if (!is_mac) {
|
| }
|
| }
|
|
|
| -# On iOS the output needs to additionally be copied to another location, so
|
| -# we have this intermediate step.
|
| +# On iOS and Mac the string resources need to go into a locale subfolder, which
|
| +# introduces an extra dependency.
|
| #
|
| # GYP version: ui/resources/ui_resources.gyp:ui_test_pak
|
| # (copy_ui_test_pak action)
|
| -if (is_ios) {
|
| - copy("ui_test_pak") {
|
| - sources = [ "$root_out_dir/ui_test.pak" ]
|
| - outputs = [ "$root_out_dir/ui/en.lproj/locale.pak" ]
|
| - deps = [ ":repack_ui_test_pak" ]
|
| +if (is_ios || is_mac) {
|
| + group("ui_test_pak") {
|
| + deps = [ ":repack_ui_test_pak", ":repack_ui_test_mac_locale_pack" ]
|
| }
|
| } else {
|
| group("ui_test_pak") {
|
| @@ -74,7 +72,7 @@ repack("repack_ui_test_pak") {
|
| # Depend on ui_test_pak instead of this one.
|
| visibility = [ ":ui_test_pak" ]
|
|
|
| - sources = [
|
| + sources = [
|
| "$root_gen_dir/ui/resources/ui_resources_100_percent.pak",
|
| "$root_gen_dir/ui/resources/webui_resources.pak",
|
| "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak",
|
| @@ -92,3 +90,22 @@ repack("repack_ui_test_pak") {
|
| deps += [ ":copy_ui_resources_100_percent" ]
|
| }
|
| }
|
| +
|
| +# Repack just the strings for the framework locales on Mac and iOS. This
|
| +# emulates repack_locales.py, but just for en-US. Note ui_test.pak is not simply
|
| +# copied, because it causes leaks from allocations within system libraries when
|
| +# trying to load non-string resources. http://crbug.com/413034.
|
| +repack("repack_ui_test_mac_locale_pack") {
|
| + visibility = [ ":ui_test_pak" ]
|
| +
|
| + sources = [
|
| + "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak",
|
| + "$root_gen_dir/ui/strings/ui_strings_en-US.pak",
|
| + ]
|
| +
|
| + output = "$root_out_dir/ui/en.lproj/locale.pak"
|
| +
|
| + deps = [
|
| + "//ui/strings",
|
| + ]
|
| +}
|
|
|