OLD | NEW |
| (Empty) |
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. | |
4 | |
5 component("ipc") { | |
6 sources = [ | |
7 "file_descriptor_set_posix.cc", | |
8 "file_descriptor_set_posix.h", | |
9 "ipc_channel.cc", | |
10 "ipc_channel.h", | |
11 "ipc_channel_factory.cc", | |
12 "ipc_channel_factory.h", | |
13 "ipc_channel_handle.h", | |
14 "ipc_channel_nacl.cc", | |
15 "ipc_channel_nacl.h", | |
16 "ipc_channel_posix.cc", | |
17 "ipc_channel_posix.h", | |
18 "ipc_channel_proxy.cc", | |
19 "ipc_channel_proxy.h", | |
20 "ipc_channel_reader.cc", | |
21 "ipc_channel_reader.h", | |
22 "ipc_channel_win.cc", | |
23 "ipc_channel_win.h", | |
24 "ipc_descriptors.h", | |
25 "ipc_export.h", | |
26 "ipc_forwarding_message_filter.cc", | |
27 "ipc_forwarding_message_filter.h", | |
28 "ipc_listener.h", | |
29 "ipc_logging.cc", | |
30 "ipc_logging.h", | |
31 "ipc_message.cc", | |
32 "ipc_message.h", | |
33 "ipc_message_macros.h", | |
34 "ipc_message_start.h", | |
35 "ipc_message_utils.cc", | |
36 "ipc_message_utils.h", | |
37 "ipc_param_traits.h", | |
38 "ipc_platform_file.cc", | |
39 "ipc_platform_file.h", | |
40 "ipc_sender.h", | |
41 "ipc_switches.cc", | |
42 "ipc_switches.h", | |
43 "ipc_sync_channel.cc", | |
44 "ipc_sync_channel.h", | |
45 "ipc_sync_message.cc", | |
46 "ipc_sync_message.h", | |
47 "ipc_sync_message_filter.cc", | |
48 "ipc_sync_message_filter.h", | |
49 "param_traits_log_macros.h", | |
50 "param_traits_macros.h", | |
51 "param_traits_read_macros.h", | |
52 "param_traits_write_macros.h", | |
53 "struct_constructor_macros.h", | |
54 "struct_destructor_macros.h", | |
55 "unix_domain_socket_util.cc", | |
56 "unix_domain_socket_util.h", | |
57 ] | |
58 | |
59 #if (!is_untrusted_nacl) { | |
60 sources -= [ | |
61 "ipc_channel_nacl.cc", | |
62 "ipc_channel_nacl.h", | |
63 ] | |
64 | |
65 if (is_win || is_ios) { | |
66 sources -= [ | |
67 "ipc_channel_factory.cc", | |
68 "unix_domain_socket_util.cc", | |
69 ] | |
70 } | |
71 | |
72 defines = [ "IPC_IMPLEMENTATION" ] | |
73 | |
74 deps = [ | |
75 "//base", | |
76 # TODO(viettrungluu): Needed for base/lazy_instance.h, which is suspect. | |
77 "//base/third_party/dynamic_annotations", | |
78 ] | |
79 } | |
80 | |
81 test("ipc_tests") { | |
82 sources = [ | |
83 "file_descriptor_set_posix_unittest.cc", | |
84 "ipc_channel_posix_unittest.cc", | |
85 "ipc_channel_unittest.cc", | |
86 "ipc_fuzzing_tests.cc", | |
87 "ipc_message_unittest.cc", | |
88 "ipc_message_utils_unittest.cc", | |
89 "ipc_send_fds_test.cc", | |
90 "ipc_sync_channel_unittest.cc", | |
91 "ipc_sync_message_unittest.cc", | |
92 "ipc_sync_message_unittest.h", | |
93 "ipc_test_base.cc", | |
94 "ipc_test_base.h", | |
95 "sync_socket_unittest.cc", | |
96 "unix_domain_socket_util_unittest.cc", | |
97 ] | |
98 | |
99 #if (toolkit_uses_gtk) { | |
100 # deps += "/build/linux/system:gtk" | |
101 #} | |
102 if (is_win || is_ios) { | |
103 sources -= "unix_domain_socket_util_unittest.cc" | |
104 } | |
105 #if (is_android && gtest_target_type == "shared_library") { | |
106 # deps += "/testing/android/native_test.gyp:native_testNative_code" | |
107 #} | |
108 #if (is_posix && !is_mac && !is_android) { | |
109 # if (linux_use_tcmalloc) { | |
110 # deps += "/base/allocator" | |
111 # } | |
112 #} | |
113 | |
114 deps = [ | |
115 ":ipc", | |
116 ":test_support_ipc", | |
117 "//base", | |
118 "//base:base_i18n", | |
119 "//base:run_all_unittests", | |
120 "//base:test_support_base", | |
121 "//testing:gtest", | |
122 ] | |
123 } | |
124 | |
125 test("ipc_perftests") { | |
126 sources = [ | |
127 "ipc_perftests.cc", | |
128 "ipc_test_base.cc", | |
129 "ipc_test_base.h", | |
130 ] | |
131 | |
132 #if (toolkit_uses_gtk) { | |
133 # deps += "/build/linux/system:gtk" | |
134 #} | |
135 #if (is_android && gtest_target_type == "shared_library") { | |
136 # deps += "/testing/android/native_test.gyp:native_testNative_code" | |
137 #} | |
138 #if (is_posix && !is_mac && !is_android) { | |
139 # if (linux_use_tcmalloc) { | |
140 # deps += "/base/allocator" | |
141 # } | |
142 #} | |
143 | |
144 deps = [ | |
145 ":ipc", | |
146 ":test_support_ipc", | |
147 "//base", | |
148 "//base:base_i18n", | |
149 "//base:test_support_base", | |
150 "//base:test_support_perf", | |
151 "//testing:gtest", | |
152 ] | |
153 } | |
154 | |
155 static_library("test_support_ipc") { | |
156 sources = [ | |
157 "ipc_multiprocess_test.cc", | |
158 "ipc_multiprocess_test.h", | |
159 "ipc_test_sink.cc", | |
160 "ipc_test_sink.h", | |
161 ] | |
162 deps = [ | |
163 ":ipc", | |
164 "//base", | |
165 "//testing:gtest", | |
166 ] | |
167 } | |
168 | |
OLD | NEW |