Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(411)

Unified Diff: remoting/remoting.gyp

Issue 18868009: Generate the lists of localization files instead of hardcoding them. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Updating DEPS and path to jinja2. Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/gyp_chromium ('k') | remoting/tools/DEPS » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/remoting.gyp
diff --git a/remoting/remoting.gyp b/remoting/remoting.gyp
index 375f56204115ae7fc18dec48546b4635138e7cb4..c9fff59b6f59c73de75690685977c2c78c3b2214 100644
--- a/remoting/remoting.gyp
+++ b/remoting/remoting.gyp
@@ -20,7 +20,7 @@
'remoting_multi_process%': '<(remoting_multi_process)',
'remoting_rdp_session%': 1,
- 'localize_py_path': 'tools/localize.py',
+ 'remoting_localize_path': 'tools/build/remoting_localize.py',
# The |major|, |build| and |patch| versions are inherited from Chrome.
# Since Chrome's |minor| version is always '0', we replace it with a
@@ -100,93 +100,18 @@
'rdp_desktop_session_clsid': '<!(python tools/uuidgen.py 2)',
}],
],
- 'remoting_languages': [
- '-l', 'ar',
- '-l', 'bg',
- '-l', 'ca',
- '-l', 'cs',
- '-l', 'da',
- '-l', 'de',
- '-l', 'el',
- '-l', 'en',
- '-l', 'en_GB',
- '-l', 'es',
- '-l', 'es_419',
- '-l', 'et',
- '-l', 'fi',
- '-l', 'fil',
- '-l', 'fr',
- '-l', 'he',
- '-l', 'hi',
- '-l', 'hr',
- '-l', 'hu',
- '-l', 'id',
- '-l', 'it',
- '-l', 'ja',
- '-l', 'ko',
- '-l', 'lt',
- '-l', 'lv',
- '-l', 'nb',
- '-l', 'nl',
- '-l', 'pl',
- '-l', 'pt_BR',
- '-l', 'pt_PT',
- '-l', 'ro',
- '-l', 'ru',
- '-l', 'sk',
- '-l', 'sl',
- '-l', 'sr',
- '-l', 'sv',
- '-l', 'th',
- '-l', 'tr',
- '-l', 'uk',
- '-l', 'vi',
- '-l', 'zh_CN',
- '-l', 'zh_TW',
+ 'remoting_locales': [
+ 'ar', 'bg', 'ca', 'cs', 'da', 'de', 'el', 'en', 'en-GB', 'es',
+ 'es-419', 'et', 'fi', 'fil', 'fr', 'he', 'hi', 'hr', 'hu', 'id',
+ 'it', 'ja', 'ko', 'lt', 'lv', 'nb', 'nl', 'pl', 'pt-BR', 'pt-PT',
+ 'ro', 'ru', 'sk', 'sl', 'sr', 'sv', 'th', 'tr', 'uk', 'vi',
+ 'zh-CN', 'zh-TW',
],
'remoting_webapp_locale_files': [
- '<(webapp_locale_dir)/ar/messages.json',
- '<(webapp_locale_dir)/bg/messages.json',
- '<(webapp_locale_dir)/ca/messages.json',
- '<(webapp_locale_dir)/cs/messages.json',
- '<(webapp_locale_dir)/da/messages.json',
- '<(webapp_locale_dir)/de/messages.json',
- '<(webapp_locale_dir)/el/messages.json',
- '<(webapp_locale_dir)/en/messages.json',
- '<(webapp_locale_dir)/en_GB/messages.json',
- '<(webapp_locale_dir)/es/messages.json',
- '<(webapp_locale_dir)/es_419/messages.json',
- '<(webapp_locale_dir)/et/messages.json',
- '<(webapp_locale_dir)/fi/messages.json',
- '<(webapp_locale_dir)/fil/messages.json',
- '<(webapp_locale_dir)/fr/messages.json',
- '<(webapp_locale_dir)/he/messages.json',
- '<(webapp_locale_dir)/hi/messages.json',
- '<(webapp_locale_dir)/hr/messages.json',
- '<(webapp_locale_dir)/hu/messages.json',
- '<(webapp_locale_dir)/id/messages.json',
- '<(webapp_locale_dir)/it/messages.json',
- '<(webapp_locale_dir)/ja/messages.json',
- '<(webapp_locale_dir)/ko/messages.json',
- '<(webapp_locale_dir)/lt/messages.json',
- '<(webapp_locale_dir)/lv/messages.json',
- '<(webapp_locale_dir)/nb/messages.json',
- '<(webapp_locale_dir)/nl/messages.json',
- '<(webapp_locale_dir)/pl/messages.json',
- '<(webapp_locale_dir)/pt_BR/messages.json',
- '<(webapp_locale_dir)/pt_PT/messages.json',
- '<(webapp_locale_dir)/ro/messages.json',
- '<(webapp_locale_dir)/ru/messages.json',
- '<(webapp_locale_dir)/sk/messages.json',
- '<(webapp_locale_dir)/sl/messages.json',
- '<(webapp_locale_dir)/sr/messages.json',
- '<(webapp_locale_dir)/sv/messages.json',
- '<(webapp_locale_dir)/th/messages.json',
- '<(webapp_locale_dir)/tr/messages.json',
- '<(webapp_locale_dir)/uk/messages.json',
- '<(webapp_locale_dir)/vi/messages.json',
- '<(webapp_locale_dir)/zh_CN/messages.json',
- '<(webapp_locale_dir)/zh_TW/messages.json',
+ # Build the list of .json files generated from remoting_strings.grd.
+ '<!@pymod_do_main(remoting_localize --locale_output '
+ '"<(webapp_locale_dir)/${json_suffix}/messages.json" '
+ '--print_only <(remoting_locales))',
],
'remoting_webapp_files': [
'resources/chromoting16.webp',
@@ -1619,11 +1544,11 @@
],
'action': [
'python',
- '<(localize_py_path)',
- '<@(remoting_languages)',
- '--messages_path', '<(webapp_locale_dir)',
- '<(RULE_INPUT_PATH)',
- '<@(_outputs)',
+ '<(remoting_localize_path)',
+ '--locale_dir', '<(webapp_locale_dir)',
+ '--template', '<(RULE_INPUT_PATH)',
+ '--output', '<@(_outputs)',
+ '<@(remoting_locales)',
],
'message': 'Localizing the dialogs and strings'
},
@@ -1778,11 +1703,11 @@
],
'action': [
'python',
- '<(localize_py_path)',
- '<@(remoting_languages)',
- '--messages_path', '<(webapp_locale_dir)',
- '<(RULE_INPUT_PATH)',
- '<@(_outputs)',
+ '<(remoting_localize_path)',
+ '--locale_dir', '<(webapp_locale_dir)',
+ '--template', '<(RULE_INPUT_PATH)',
+ '--output', '<@(_outputs)',
+ '<@(remoting_locales)',
],
'message': 'Localizing the event log messages'
},
@@ -1862,16 +1787,16 @@
],
'action': [
'python',
- '<(localize_py_path)',
- '<@(remoting_languages)',
- '-i', '<(chrome_version_path)',
+ '<(remoting_localize_path)',
+ '--variables', '<(chrome_version_path)',
# |remoting_version_path| must be after |chrome_version_path|
# because it can contain overrides for the version numbers.
- '-i', '<(remoting_version_path)',
- '-i', '<(lastchange_path)',
- '--messages_path', '<(webapp_locale_dir)',
- '<(RULE_INPUT_PATH)',
- '<@(_outputs)',
+ '--variables', '<(remoting_version_path)',
+ '--variables', '<(lastchange_path)',
+ '--locale_dir', '<(webapp_locale_dir)',
+ '--template', '<(RULE_INPUT_PATH)',
+ '--output', '<@(_outputs)',
+ '<@(remoting_locales)',
],
'message': 'Localizing the version information'
},
@@ -2367,48 +2292,10 @@
{
'destination': '<(PRODUCT_DIR)/remoting_locales',
'files': [
- '<(grit_out_dir)/remoting/resources/ar.pak',
- '<(grit_out_dir)/remoting/resources/bg.pak',
- '<(grit_out_dir)/remoting/resources/ca.pak',
- '<(grit_out_dir)/remoting/resources/cs.pak',
- '<(grit_out_dir)/remoting/resources/da.pak',
- '<(grit_out_dir)/remoting/resources/de.pak',
- '<(grit_out_dir)/remoting/resources/el.pak',
- '<(grit_out_dir)/remoting/resources/en-US.pak',
- '<(grit_out_dir)/remoting/resources/en-GB.pak',
- '<(grit_out_dir)/remoting/resources/es.pak',
- '<(grit_out_dir)/remoting/resources/es-419.pak',
- '<(grit_out_dir)/remoting/resources/et.pak',
- '<(grit_out_dir)/remoting/resources/fi.pak',
- '<(grit_out_dir)/remoting/resources/fil.pak',
- '<(grit_out_dir)/remoting/resources/fr.pak',
- '<(grit_out_dir)/remoting/resources/he.pak',
- '<(grit_out_dir)/remoting/resources/hi.pak',
- '<(grit_out_dir)/remoting/resources/hr.pak',
- '<(grit_out_dir)/remoting/resources/hu.pak',
- '<(grit_out_dir)/remoting/resources/id.pak',
- '<(grit_out_dir)/remoting/resources/it.pak',
- '<(grit_out_dir)/remoting/resources/ja.pak',
- '<(grit_out_dir)/remoting/resources/ko.pak',
- '<(grit_out_dir)/remoting/resources/lt.pak',
- '<(grit_out_dir)/remoting/resources/lv.pak',
- '<(grit_out_dir)/remoting/resources/nb.pak',
- '<(grit_out_dir)/remoting/resources/nl.pak',
- '<(grit_out_dir)/remoting/resources/pl.pak',
- '<(grit_out_dir)/remoting/resources/pt-BR.pak',
- '<(grit_out_dir)/remoting/resources/pt-PT.pak',
- '<(grit_out_dir)/remoting/resources/ro.pak',
- '<(grit_out_dir)/remoting/resources/ru.pak',
- '<(grit_out_dir)/remoting/resources/sk.pak',
- '<(grit_out_dir)/remoting/resources/sl.pak',
- '<(grit_out_dir)/remoting/resources/sr.pak',
- '<(grit_out_dir)/remoting/resources/sv.pak',
- '<(grit_out_dir)/remoting/resources/th.pak',
- '<(grit_out_dir)/remoting/resources/tr.pak',
- '<(grit_out_dir)/remoting/resources/uk.pak',
- '<(grit_out_dir)/remoting/resources/vi.pak',
- '<(grit_out_dir)/remoting/resources/zh-CN.pak',
- '<(grit_out_dir)/remoting/resources/zh-TW.pak',
+ # Build the list of .pak files generated from remoting_strings.grd.
+ '<!@pymod_do_main(remoting_localize --locale_output '
+ '"<(grit_out_dir)/remoting/resources/${pak_suffix}.pak" '
+ '--print_only <(remoting_locales))',
],
},
{
« no previous file with comments | « build/gyp_chromium ('k') | remoting/tools/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698