Add UMAs to measure Android tab state transition
[chromium-blink-merge.git] / ipc / ipc.gyp
blobfb64c329e314e265d65f4bc16c9f772ed3a9285b
1 # Copyright (c) 2012 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   },
9   'includes': [
10     'ipc.gypi',
11   ],
12   'targets': [
13     {
14       'target_name': 'ipc',
15       'type': '<(component)',
16       'variables': {
17         'ipc_target': 1,
18       },
19       'dependencies': [
20         '../base/base.gyp:base',
21         # TODO(viettrungluu): Needed for base/lazy_instance.h, which is suspect.
22         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
23         '../crypto/crypto.gyp:crypto',
24       ],
25       # TODO(gregoryd): direct_dependent_settings should be shared with the
26       # 64-bit target, but it doesn't work due to a bug in gyp
27       'direct_dependent_settings': {
28         'include_dirs': [
29           '..',
30         ],
31       },
32     },
33     {
34       'target_name': 'ipc_tests',
35       'type': '<(gtest_target_type)',
36       'dependencies': [
37         'ipc',
38         'test_support_ipc',
39         '../base/base.gyp:base',
40         '../base/base.gyp:base_i18n',
41         '../base/base.gyp:test_support_base',
42         '../testing/gtest.gyp:gtest',
43       ],
44       'include_dirs': [
45         '..'
46       ],
47       'sources': [
48         'attachment_broker_privileged_win_unittest.cc',
49         'attachment_broker_unprivileged_win_unittest.cc',
50         'ipc_channel_posix_unittest.cc',
51         'ipc_channel_proxy_unittest.cc',
52         'ipc_channel_reader_unittest.cc',
53         'ipc_channel_unittest.cc',
54         'ipc_fuzzing_tests.cc',
55         'ipc_message_attachment_set_posix_unittest.cc',
56         'ipc_message_unittest.cc',
57         'ipc_message_utils_unittest.cc',
58         'ipc_send_fds_test.cc',
59         'ipc_sync_channel_unittest.cc',
60         'ipc_sync_message_unittest.cc',
61         'ipc_sync_message_unittest.h',
62         'run_all_unittests.cc',
63         'sync_socket_unittest.cc',
64         'unix_domain_socket_util_unittest.cc',
65       ],
66       'conditions': [
67         ['OS == "win" or OS == "ios"', {
68           'sources!': [
69             'unix_domain_socket_util_unittest.cc',
70           ],
71         }],
72         ['OS == "android"', {
73           'dependencies': [
74             '../testing/android/native_test.gyp:native_test_native_code',
75           ],
76         }],
77         ['os_posix == 1 and OS != "mac" and OS != "android"', {
78           'conditions': [
79             ['use_allocator!="none"', {
80               'dependencies': [
81                 '../base/allocator/allocator.gyp:allocator',
82               ],
83             }],
84           ],
85         }]
86       ],
87     },
88     {
89       'target_name': 'ipc_perftests',
90       'type': '<(gtest_target_type)',
91       # TODO(viettrungluu): Figure out which dependencies are really needed.
92       'dependencies': [
93         'ipc',
94         'test_support_ipc',
95         '../base/base.gyp:base',
96         '../base/base.gyp:base_i18n',
97         '../base/base.gyp:test_support_base',
98         '../base/base.gyp:test_support_perf',
99         '../testing/gtest.gyp:gtest',
100       ],
101       'include_dirs': [
102         '..'
103       ],
104       'sources': [
105         'ipc_perftests.cc',
106         'ipc_test_base.cc',
107         'ipc_test_base.h',
108       ],
109       'conditions': [
110         ['OS == "android"', {
111           'dependencies': [
112             '../testing/android/native_test.gyp:native_test_native_code',
113           ],
114         }],
115         ['os_posix == 1 and OS != "mac" and OS != "android"', {
116           'conditions': [
117             ['use_allocator!="none"', {
118               'dependencies': [
119                 '../base/allocator/allocator.gyp:allocator',
120               ],
121             }],
122           ],
123         }]
124       ],
125     },
126     {
127       'target_name': 'test_support_ipc',
128       'type': 'static_library',
129       'dependencies': [
130         'ipc',
131         '../base/base.gyp:base',
132         '../testing/gtest.gyp:gtest',
133       ],
134       'sources': [
135         'ipc_multiprocess_test.cc',
136         'ipc_multiprocess_test.h',
137         'ipc_perftest_support.cc',
138         'ipc_perftest_support.h',
139         'ipc_security_test_util.cc',
140         'ipc_security_test_util.h',
141         'ipc_test_base.cc',
142         'ipc_test_base.h',
143         'ipc_test_channel_listener.cc',
144         'ipc_test_channel_listener.h',
145         'ipc_test_sink.cc',
146         'ipc_test_sink.h',
147       ],
148     },
149   ],
150   'conditions': [
151     ['OS=="win" and target_arch=="ia32"', {
152       'targets': [
153         {
154           'target_name': 'ipc_win64',
155           'type': '<(component)',
156           'variables': {
157             'ipc_target': 1,
158           },
159           'dependencies': [
160             '../base/base.gyp:base_win64',
161             # TODO(viettrungluu): Needed for base/lazy_instance.h, which is
162             # suspect.
163             '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations_win64',
164             '../crypto/crypto.gyp:crypto_nacl_win64',
165           ],
166           # TODO(gregoryd): direct_dependent_settings should be shared with the
167           # 32-bit target, but it doesn't work due to a bug in gyp
168           'direct_dependent_settings': {
169             'include_dirs': [
170               '..',
171             ],
172           },
173           'configurations': {
174             'Common_Base': {
175               'msvs_target_platform': 'x64',
176             },
177           },
178         },
179       ],
180     }],
181     ['OS == "android"', {
182       'targets': [
183         {
184           'target_name': 'ipc_tests_apk',
185           'type': 'none',
186           'dependencies': [
187             'ipc_tests',
188           ],
189           'variables': {
190             'test_suite_name': 'ipc_tests',
191           },
192           'includes': [ '../build/apk_test.gypi' ],
193         },
194         {
195           'target_name': 'ipc_perftests_apk',
196           'type': 'none',
197           'dependencies': [
198             'ipc_perftests',
199           ],
200           'variables': {
201             'test_suite_name': 'ipc_perftests',
202           },
203           'includes': [ '../build/apk_test.gypi' ],
204         }],
205     }],
206     ['test_isolation_mode != "noop"', {
207       'targets': [
208         {
209           'target_name': 'ipc_tests_run',
210           'type': 'none',
211           'dependencies': [
212             'ipc_tests',
213           ],
214           'includes': [
215             '../build/isolate.gypi',
216           ],
217           'sources': [
218             'ipc_tests.isolate',
219           ],
220         },
221       ],
222     }],
223   ],