ChildAccountService[Java] delegates everything to native side.
[chromium-blink-merge.git] / ui / accessibility / accessibility.gyp
blob0cb22a7f85e34a048a54733fe1e193bdf169dc2c
1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
6   'variables': {
7     'chromium_code': 1,
8   },
10   'targets': [
11     {
12       'target_name': 'accessibility',
13       'type': '<(component)',
14       'export_dependent_settings': [
15         'ax_gen',
16       ],
17       'hard_dependency': 1,
18       'dependencies': [
19         '../../base/base.gyp:base',
20         '../gfx/gfx.gyp:gfx',
21         '../gfx/gfx.gyp:gfx_geometry',
22         'ax_gen',
23       ],
24       'defines': [
25         'ACCESSIBILITY_IMPLEMENTATION',
26       ],
27       'sources': [
28         # All .cc, .h under accessibility, except unittests
29         'ax_node.cc',
30         'ax_node.h',
31         'ax_node_data.cc',
32         'ax_node_data.h',
33         'ax_serializable_tree.cc',
34         'ax_serializable_tree.h',
35         'ax_text_utils.cc',
36         'ax_text_utils.h',
37         'ax_tree.cc',
38         'ax_tree.h',
39         'ax_tree_serializer.cc',
40         'ax_tree_serializer.h',
41         'ax_tree_source.h',
42         'ax_tree_update.h',
43         'ax_view_state.cc',
44         'ax_view_state.h',
45         'platform/atk_util_auralinux.cc',
46         'platform/atk_util_auralinux.h',
47         'platform/ax_platform_node.cc',
48         'platform/ax_platform_node.h',
49         'platform/ax_platform_node_auralinux.cc',
50         'platform/ax_platform_node_auralinux.h',
51         'platform/ax_platform_node_base.cc',
52         'platform/ax_platform_node_base.h',
53         'platform/ax_platform_node_delegate.h',
54         'platform/ax_platform_node_mac.h',
55         'platform/ax_platform_node_mac.mm',
56         'platform/ax_platform_node_win.h',
57         'platform/ax_platform_node_win.cc',
58       ],
59       'conditions': [
60         ['OS=="win"', {
61           'dependencies': [
62             '../../third_party/iaccessible2/iaccessible2.gyp:iaccessible2'
63           ],
64         }],
65         ['OS=="linux" and chromeos==0 and use_x11==1', {
66           'dependencies': [
67             '../../build/linux/system.gyp:atk',
68             '../../build/linux/system.gyp:gconf',
69             '../../build/linux/system.gyp:glib',
70           ],
71           'variables': {
72             'clang_warning_flags': [
73               # glib uses the pre-c++11 typedef-as-static_assert hack.
74               '-Wno-unused-local-typedefs',
75               # G_DEFINE_TYPE automatically generates a
76               # *get_instance_private inline function after glib 2.37.
77               # That's unused. Prevent to complain about it.
78               '-Wno-unused-function',
79             ],
80           },
81         }],
82         ['OS!="linux" or chromeos==1 or use_x11==0', {
83           'sources!': [
84             'platform/ax_platform_node_auralinux.cc',
85             'platform/ax_platform_node_auralinux.h',
86             'platform/atk_util_auralinux.cc',
87             'platform/atk_util_auralinux.h',
88           ],
89         }],
90         ['OS=="android"', {
91           'dependencies': [
92             'ui_accessibility_java'
93           ],
94         }],
95       ],
96     },
97     {
98       'target_name': 'accessibility_test_support',
99       'type': 'static_library',
100       'dependencies': [
101         '../../base/base.gyp:base',
102         'accessibility'
103       ],
104       'sources': [
105         'platform/test_ax_node_wrapper.cc',
106         'platform/test_ax_node_wrapper.h',
107         'tree_generator.cc',
108         'tree_generator.h',
109       ]
110     },
111     {
112       'target_name': 'accessibility_unittests',
113       'type': 'executable',
114       'dependencies': [
115         '../../base/base.gyp:base',
116         '../../base/base.gyp:run_all_unittests',
117         '../../testing/gtest.gyp:gtest',
118         '../gfx/gfx.gyp:gfx',
119         '../gfx/gfx.gyp:gfx_geometry',
120         'accessibility',
121         'accessibility_test_support',
122         'ax_gen',
123       ],
124       'sources': [
125         'ax_generated_tree_unittest.cc',
126         'ax_text_utils_unittest.cc',
127         'ax_tree_serializer_unittest.cc',
128         'ax_tree_unittest.cc',
129         'platform/ax_platform_node_win_unittest.cc'
130       ],
131       'conditions': [
132         ['OS=="win"', {
133           'dependencies': [
134             '../../third_party/iaccessible2/iaccessible2.gyp:iaccessible2'
135           ],
136         }],
137       ],
138     },
139     {
140       'target_name': 'ax_gen',
141       'type': 'static_library',
142       # This target exports a hard dependency because dependent targets may
143       # include ax_enums.h, a generated header.
144       'hard_dependency': 1,
145       'dependencies': [
146         '../../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations'
147         ],
148       'sources': [
149         '<@(schema_files)',
150       ],
151       'msvs_disabled_warnings': [ 4267 ],
152       'includes': [
153         '../../build/json_schema_compile.gypi',
154       ],
155       'variables': {
156         'chromium_code': 1,
157         'schema_files': [
158           'ax_enums.idl',
159         ],
160         'non_compiled_schema_files': [],
161         'cc_dir': 'ui/accessibility',
162         # TODO(dtseng): Change this once all files under ui/accessibility
163         # namespaced under ui::ax.
164         'root_namespace': 'ui',
165       },
166     },
167   ],
168   'conditions': [
169     ['test_isolation_mode != "noop"', {
170       'targets': [
171         {
172           'target_name': 'accessibility_unittests_run',
173           'type': 'none',
174           'dependencies': [
175             'accessibility_unittests',
176           ],
177           'includes': [
178             '../../build/isolate.gypi',
179           ],
180           'sources': [
181             'accessibility_unittests.isolate',
182           ],
183           'conditions': [
184             ['use_x11 == 1', {
185               'dependencies': [
186                 '../../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
187               ],
188             }],
189           ],
190         },
191       ],
192     }],
193     ['OS == "android"', {
194       'targets': [
195         {
196           'target_name': 'ui_accessibility_java',
197           'type': 'none',
198           'variables': {
199             'java_in_dir': '<(DEPTH)/build/android/empty',
200             'has_java_resources': 0,
201           },
202           'dependencies': [
203             'ax_enumerations_java',
204           ],
205           'includes': [ '../../build/java.gypi' ],
206         },
207         {
208           'target_name': 'ax_enumerations_java',
209           'type': 'none',
210           'variables': {
211             'source_file': 'ax_enums.idl',
212           },
213           'includes': [ '../../build/android/java_cpp_enum.gypi' ],
214         },
215       ],
216     }],
217   ],