OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//tools/grit/grit_rule.gni") | 5 import("//tools/grit/grit_rule.gni") |
6 | 6 |
7 # See also remoting_locales_with_underscores below. | 7 # See also remoting_locales_with_underscores below. |
8 remoting_locales = [ | 8 remoting_locales = [ |
| 9 "am", |
9 "ar", | 10 "ar", |
10 "bg", | 11 "bg", |
| 12 "bn", |
11 "ca", | 13 "ca", |
12 "cs", | 14 "cs", |
13 "da", | 15 "da", |
14 "de", | 16 "de", |
15 "el", | 17 "el", |
16 "en", | 18 "en", |
17 "en-GB", | 19 "en-GB", |
18 "es", | 20 "es", |
19 "es-419", | 21 "es-419", |
20 "et", | 22 "et", |
| 23 "fa", |
| 24 "fake-bidi", |
21 "fi", | 25 "fi", |
22 "fil", | 26 "fil", |
23 "fr", | 27 "fr", |
| 28 "gu", |
24 "he", | 29 "he", |
25 "hi", | 30 "hi", |
26 "hr", | 31 "hr", |
27 "hu", | 32 "hu", |
28 "id", | 33 "id", |
29 "it", | 34 "it", |
30 "ja", | 35 "ja", |
| 36 "kn", |
31 "ko", | 37 "ko", |
32 "lt", | 38 "lt", |
33 "lv", | 39 "lv", |
| 40 "ml", |
| 41 "mr", |
| 42 "ms", |
34 "nb", | 43 "nb", |
35 "nl", | 44 "nl", |
36 "pl", | 45 "pl", |
37 "pt-BR", | 46 "pt-BR", |
38 "pt-PT", | 47 "pt-PT", |
39 "ro", | 48 "ro", |
40 "ru", | 49 "ru", |
41 "sk", | 50 "sk", |
42 "sl", | 51 "sl", |
43 "sr", | 52 "sr", |
44 "sv", | 53 "sv", |
| 54 "sw", |
| 55 "ta", |
| 56 "te", |
45 "th", | 57 "th", |
46 "tr", | 58 "tr", |
47 "uk", | 59 "uk", |
48 "vi", | 60 "vi", |
49 "zh-CN", | 61 "zh-CN", |
50 "zh-TW", | 62 "zh-TW", |
51 ] | 63 ] |
52 | 64 |
53 # Some locales have hyphens in the names but for some uses underscores are | 65 # Some locales have hyphens in the names but for some uses underscores are |
54 # needed. | 66 # needed. |
55 remoting_locales_with_underscores = remoting_locales | 67 remoting_locales_with_underscores = remoting_locales |
56 remoting_locales_with_underscores -= [ | 68 remoting_locales_with_underscores -= [ |
57 "en-GB", | 69 "en-GB", |
58 "es-419", | 70 "es-419", |
| 71 "fake-bidi", |
59 "pt-BR", | 72 "pt-BR", |
60 "pt-PT", | 73 "pt-PT", |
61 "zh-CN", | 74 "zh-CN", |
62 "zh-TW", | 75 "zh-TW", |
63 ] | 76 ] |
64 remoting_locales_with_underscores += [ | 77 remoting_locales_with_underscores += [ |
65 "en_GB", | 78 "en_GB", |
66 "es_419", | 79 "es_419", |
| 80 "fake_bidi", |
67 "pt_BR", | 81 "pt_BR", |
68 "pt_PT", | 82 "pt_PT", |
69 "zh_CN", | 83 "zh_CN", |
70 "zh_TW", | 84 "zh_TW", |
71 ] | 85 ] |
72 | 86 |
| 87 if (is_chromeos) { |
| 88 remoting_locales += ["en-US"] |
| 89 remoting_locales_with_underscores += ["en_US"] |
| 90 } |
| 91 |
73 group("resources") { | 92 group("resources") { |
74 deps = [ | 93 deps = [ |
75 ":copy_locales", | 94 ":copy_locales", |
76 ":strings", | 95 ":strings", |
77 #":verify_resources", TODO(GYP) enable this. | 96 #":verify_resources", TODO(GYP) enable this. |
78 ] | 97 ] |
79 } | 98 } |
80 | 99 |
81 # TODO(GYP) enable verify_resources. The bots are complaining about | 100 # TODO(GYP) enable verify_resources. The bots are complaining about |
82 # gen/main.html not being found but this doesn't seems to reproduce locally. | 101 # gen/main.html not being found but this doesn't seems to reproduce locally. |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 } # if false | 146 } # if false |
128 | 147 |
129 grit("strings") { | 148 grit("strings") { |
130 source = "remoting_strings.grd" | 149 source = "remoting_strings.grd" |
131 output_name = "remoting_strings" | 150 output_name = "remoting_strings" |
132 | 151 |
133 # The grd file encodes "remoting/..." in the name, so root everything in the | 152 # The grd file encodes "remoting/..." in the name, so root everything in the |
134 # generated file root. | 153 # generated file root. |
135 output_dir = root_gen_dir | 154 output_dir = root_gen_dir |
136 | 155 |
137 resource_ids = "resource_ids" | |
138 | |
139 outputs = [ | 156 outputs = [ |
140 "remoting/base/string_resources.h", | 157 "remoting/base/string_resources.h", |
141 ] | 158 ] |
142 | 159 |
143 # The grd produces a *.pak file and a messages.json file (this one uses | 160 # The grd produces a *.pak file and a messages.json file (this one uses |
144 # underscores instead of hyphens) for each locale. | 161 # underscores instead of hyphens) for each locale. |
145 outputs += process_file_template( | 162 outputs += process_file_template( |
146 remoting_locales, | 163 remoting_locales, |
147 [ "remoting/resources/{{source_name_part}}.pak" ]) | 164 [ "remoting/resources/{{source_name_part}}.pak" ]) |
148 outputs += process_file_template( | 165 outputs += process_file_template( |
(...skipping 26 matching lines...) Expand all Loading... |
175 } | 192 } |
176 | 193 |
177 args = [ | 194 args = [ |
178 "-p", os, | 195 "-p", os, |
179 "-g", rebase_path(root_gen_dir, root_build_dir), | 196 "-g", rebase_path(root_gen_dir, root_build_dir), |
180 "-x", rebase_path(root_out_dir, root_build_dir), | 197 "-x", rebase_path(root_out_dir, root_build_dir), |
181 ] + remoting_locales | 198 ] + remoting_locales |
182 | 199 |
183 deps = [ ":strings" ] | 200 deps = [ ":strings" ] |
184 } | 201 } |
OLD | NEW |