Chromium Code Reviews| Index: icu.gyp |
| diff --git a/icu.gyp b/icu.gyp |
| index 38d29397b8401f524780f99cedb0216b9320f6b7..b6cc8f9213ab2ae723c6008fbbde8c0f74b6e7a3 100644 |
| --- a/icu.gyp |
| +++ b/icu.gyp |
| @@ -69,11 +69,22 @@ |
| 'mac/icudt46l_dat.S', |
| ], |
| 'conditions': [ |
| - [ 'use_system_icu==1', { |
| - 'toolsets': ['host'], |
| - }, { |
| + [ 'use_system_icu==1 and want_separate_host_toolset==1', { |
| + 'toolsets': ['host', 'target'], |
| + 'target_conditions': [ |
| + [ '_toolset == "target"', { |
| + 'type': 'none', |
| + 'dependencies': ['system_icudata'], |
| + 'export_dependent_settings': ['system_icudata'], |
|
dshwang
2014/01/03 20:36:42
I try to not build it for target toolset as above:
|
| + }], |
| + ], # target_conditions |
| + }], |
| + [ 'use_system_icu==0 and want_separate_host_toolset==1', { |
| 'toolsets': ['host', 'target'], |
| }], |
| + [ 'use_system_icu==0 and want_separate_host_toolset==0', { |
| + 'toolsets': ['target'], |
| + }], |
| [ 'OS == "win" and icu_use_data_file_flag==0', { |
| 'type': 'none', |
| 'copies': [ |
| @@ -122,7 +133,7 @@ |
| '(OS != "android" or _toolset != "host" or host_os != "mac")', { |
| 'sources!': ['mac/icudt46l_dat.S'], |
| }], |
| - ], |
| + ], # target_conditions |
| }, |
| { |
| 'target_name': 'icui18n', |
| @@ -142,11 +153,22 @@ |
| ], |
| }, |
| 'conditions': [ |
| - [ 'use_system_icu==1', { |
| - 'toolsets': ['host'], |
| - }, { |
| + [ 'use_system_icu==1 and want_separate_host_toolset==1', { |
| + 'toolsets': ['host', 'target'], |
| + 'target_conditions': [ |
| + [ '_toolset == "target"', { |
| + 'type': 'none', |
| + 'dependencies': ['system_icui18n'], |
| + 'export_dependent_settings': ['system_icui18n'], |
| + }], |
| + ], # target_conditions |
| + }], |
| + [ 'use_system_icu==0 and want_separate_host_toolset==1', { |
| 'toolsets': ['host', 'target'], |
| }], |
| + [ 'use_system_icu==0 and want_separate_host_toolset==0', { |
| + 'toolsets': ['target'], |
| + }], |
| [ 'os_posix == 1 and OS != "mac" and OS != "ios"', { |
| # Since ICU wants to internally use its own deprecated APIs, don't |
| # complain about it. |
| @@ -218,7 +240,7 @@ |
| }], |
| ], |
| }], |
| - ], |
| + ], # conditions |
| }, |
| { |
| 'target_name': 'icuuc', |
| @@ -245,11 +267,22 @@ |
| ], |
| }, |
| 'conditions': [ |
| - [ 'use_system_icu==1', { |
| - 'toolsets': ['host'], |
| - }, { |
| + [ 'use_system_icu==1 and want_separate_host_toolset==1', { |
| + 'toolsets': ['host', 'target'], |
| + 'target_conditions': [ |
| + [ '_toolset == "target"', { |
| + 'type': 'none', |
| + 'dependencies': ['system_icuuc'], |
| + 'export_dependent_settings': ['system_icuuc'], |
| + }], |
| + ], # target_conditions |
| + }], |
| + [ 'use_system_icu==0 and want_separate_host_toolset==1', { |
| 'toolsets': ['host', 'target'], |
| }], |
| + [ 'use_system_icu==0 and want_separate_host_toolset==0', { |
| + 'toolsets': ['target'], |
| + }], |
| [ 'OS == "win"', { |
| 'sources': [ |
| 'source/stubdata/stubdata.c', |
| @@ -318,7 +351,31 @@ |
| '-Wno-switch', |
| ], |
| }], |
| - ], |
| + ], # conditions |
| + }, |
| + ], # targets |
| + }, { # want_separate_host_toolset == 0 and use_system_icu == 1 |
| + 'targets': [ |
| + { |
| + 'target_name': 'icudata', |
| + 'type': 'none', |
| + 'dependencies': ['system_icudata'], |
| + 'export_dependent_settings': ['system_icudata'], |
| + 'toolsets': ['target'], |
| + }, |
| + { |
| + 'target_name': 'icui18n', |
| + 'type': 'none', |
| + 'dependencies': ['system_icui18n'], |
| + 'export_dependent_settings': ['system_icui18n'], |
| + 'toolsets': ['target'], |
| + }, |
| + { |
| + 'target_name': 'icuuc', |
| + 'type': 'none', |
| + 'dependencies': ['system_icuuc'], |
| + 'export_dependent_settings': ['system_icuuc'], |
| + 'toolsets': ['target'], |
| }, |
| ], |
| }], |
| @@ -328,11 +385,6 @@ |
| 'target_name': 'system_icu', |
| 'type': 'none', |
| 'conditions': [ |
| - ['want_separate_host_toolset==1', { |
| - 'toolsets': ['target'], |
| - }, { |
| - 'toolsets': ['host', 'target'], |
| - }], |
| ['OS=="android"', { |
| 'direct_dependent_settings': { |
| 'include_dirs': [ |
| @@ -359,20 +411,13 @@ |
| ], |
| }, |
| { |
| - 'target_name': 'icudata', |
| + 'target_name': 'system_icudata', |
| 'type': 'none', |
| 'dependencies': ['system_icu'], |
| 'export_dependent_settings': ['system_icu'], |
| - 'conditions': [ |
| - ['want_separate_host_toolset==1', { |
| - 'toolsets': ['target'], |
| - }, { |
| - 'toolsets': ['host', 'target'], |
| - }], |
| - ], |
| }, |
| { |
| - 'target_name': 'icui18n', |
| + 'target_name': 'system_icui18n', |
| 'type': 'none', |
| 'dependencies': ['system_icu'], |
| 'export_dependent_settings': ['system_icu'], |
| @@ -456,16 +501,9 @@ |
| 'includes': [ |
| '../../build/shim_headers.gypi', |
| ], |
| - 'conditions': [ |
| - ['want_separate_host_toolset==1', { |
| - 'toolsets': ['target'], |
| - }, { |
| - 'toolsets': ['host', 'target'], |
| - }], |
| - ], |
| }, |
| { |
| - 'target_name': 'icuuc', |
| + 'target_name': 'system_icuuc', |
| 'type': 'none', |
| 'dependencies': ['system_icu'], |
| 'export_dependent_settings': ['system_icu'], |
| @@ -567,15 +605,8 @@ |
| 'includes': [ |
| '../../build/shim_headers.gypi', |
| ], |
| - 'conditions': [ |
| - ['want_separate_host_toolset==1', { |
| - 'toolsets': ['target'], |
| - }, { |
| - 'toolsets': ['host', 'target'], |
| - }], |
| - ], |
| }, |
| - ], |
| + ], # targets |
| }], |
| - ], |
| + ], # conditions |
| } |