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