| OLD | NEW |
| 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//build/buildflag_header.gni") | 5 import("//build/buildflag_header.gni") |
| 6 import("//build/config/nacl/config.gni") | 6 import("//build/config/nacl/config.gni") |
| 7 import("//mojo/public/tools/bindings/mojom.gni") | 7 import("//mojo/public/tools/bindings/mojom.gni") |
| 8 import("//testing/test.gni") | 8 import("//testing/test.gni") |
| 9 import("//tools/ipc_fuzzer/ipc_fuzzer.gni") | 9 import("//tools/ipc_fuzzer/ipc_fuzzer.gni") |
| 10 import("//third_party/protobuf/proto_library.gni") |
| 10 | 11 |
| 11 declare_args() { | 12 declare_args() { |
| 12 # Enabling debug builds automatically sets enable_ipc_logging to true. | 13 # Enabling debug builds automatically sets enable_ipc_logging to true. |
| 13 enable_ipc_logging = is_debug | 14 enable_ipc_logging = is_debug |
| 14 } | 15 } |
| 15 | 16 |
| 16 buildflag_header("ipc_features") { | 17 buildflag_header("ipc_features") { |
| 17 header = "ipc_features.h" | 18 header = "ipc_features.h" |
| 18 | 19 |
| 19 flags = [ "IPC_MESSAGE_LOG_ENABLED=$enable_ipc_logging" ] | 20 flags = [ "IPC_MESSAGE_LOG_ENABLED=$enable_ipc_logging" ] |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 115 | 116 |
| 116 defines = [ "IPC_IMPLEMENTATION" ] | 117 defines = [ "IPC_IMPLEMENTATION" ] |
| 117 | 118 |
| 118 public_deps = [ | 119 public_deps = [ |
| 119 ":ipc_features", | 120 ":ipc_features", |
| 120 ":mojom", | 121 ":mojom", |
| 121 ":param_traits", | 122 ":param_traits", |
| 122 "//mojo/public/cpp/bindings", | 123 "//mojo/public/cpp/bindings", |
| 123 "//mojo/public/cpp/system", | 124 "//mojo/public/cpp/system", |
| 124 ] | 125 ] |
| 126 |
| 127 if (!is_nacl_nonsfi) { |
| 128 sources += [ |
| 129 "ipc_message_repeated_field_utils.h", |
| 130 ] |
| 131 |
| 132 public_deps += [ |
| 133 "//third_party/protobuf:protobuf_lite", |
| 134 ] |
| 135 } |
| 136 |
| 125 deps = [ | 137 deps = [ |
| 126 "//base", | 138 "//base", |
| 127 ] | 139 ] |
| 128 | 140 |
| 129 if (is_win || is_mac) { | 141 if (is_win || is_mac) { |
| 130 # On Windows HandleAttachmentWin needs to generate random IDs. | 142 # On Windows HandleAttachmentWin needs to generate random IDs. |
| 131 # On Mac MachPortAttachmentMac needs to generate random IDs. | 143 # On Mac MachPortAttachmentMac needs to generate random IDs. |
| 132 deps += [ "//crypto" ] | 144 deps += [ "//crypto" ] |
| 133 } | 145 } |
| 134 | 146 |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 ] | 181 ] |
| 170 | 182 |
| 171 deps = [ | 183 deps = [ |
| 172 "//base", | 184 "//base", |
| 173 "//base/test:test_support", | 185 "//base/test:test_support", |
| 174 "//mojo/edk/system", | 186 "//mojo/edk/system", |
| 175 "//mojo/edk/test:test_support", | 187 "//mojo/edk/test:test_support", |
| 176 ] | 188 ] |
| 177 } | 189 } |
| 178 | 190 |
| 191 proto_library("test_proto") { |
| 192 sources = [ |
| 193 "test_proto.proto", |
| 194 ] |
| 195 } |
| 196 |
| 179 test("ipc_tests") { | 197 test("ipc_tests") { |
| 180 sources = [ | 198 sources = [ |
| 181 "ipc_channel_mojo_unittest.cc", | 199 "ipc_channel_mojo_unittest.cc", |
| 182 "ipc_channel_proxy_unittest.cc", | 200 "ipc_channel_proxy_unittest.cc", |
| 183 "ipc_channel_reader_unittest.cc", | 201 "ipc_channel_reader_unittest.cc", |
| 184 "ipc_fuzzing_tests.cc", | 202 "ipc_fuzzing_tests.cc", |
| 185 "ipc_message_attachment_set_posix_unittest.cc", | 203 "ipc_message_attachment_set_posix_unittest.cc", |
| 186 "ipc_message_unittest.cc", | 204 "ipc_message_unittest.cc", |
| 187 "ipc_message_utils_unittest.cc", | 205 "ipc_message_utils_unittest.cc", |
| 188 "ipc_mojo_bootstrap_unittest.cc", | 206 "ipc_mojo_bootstrap_unittest.cc", |
| 189 "ipc_sync_channel_unittest.cc", | 207 "ipc_sync_channel_unittest.cc", |
| 190 "ipc_sync_message_unittest.cc", | 208 "ipc_sync_message_unittest.cc", |
| 191 "ipc_sync_message_unittest.h", | 209 "ipc_sync_message_unittest.h", |
| 192 "ipc_test_message_generator.cc", | 210 "ipc_test_message_generator.cc", |
| 193 "ipc_test_message_generator.h", | 211 "ipc_test_message_generator.h", |
| 194 "ipc_test_messages.h", | 212 "ipc_test_messages.h", |
| 195 "sync_socket_unittest.cc", | 213 "sync_socket_unittest.cc", |
| 196 ] | 214 ] |
| 197 | 215 |
| 198 if (!is_ios) { | 216 if (!is_ios) { |
| 199 sources += [ "ipc_send_fds_test.cc" ] | 217 sources += [ "ipc_send_fds_test.cc" ] |
| 200 } | 218 } |
| 201 | 219 |
| 202 deps = [ | 220 deps = [ |
| 203 ":ipc", | 221 ":ipc", |
| 204 ":run_all_unittests", | 222 ":run_all_unittests", |
| 205 ":test_interfaces", | 223 ":test_interfaces", |
| 224 ":test_proto", |
| 206 ":test_support", | 225 ":test_support", |
| 207 "//base", | 226 "//base", |
| 208 "//base:i18n", | 227 "//base:i18n", |
| 209 "//base/test:test_support", | 228 "//base/test:test_support", |
| 210 "//crypto", | 229 "//crypto", |
| 211 "//mojo/edk/system", | 230 "//mojo/edk/system", |
| 212 "//mojo/edk/test:test_support", | 231 "//mojo/edk/test:test_support", |
| 213 "//testing/gtest", | 232 "//testing/gtest", |
| 214 ] | 233 ] |
| 215 | 234 |
| 216 if (is_mac) { | 235 if (is_mac) { |
| 217 deps += [ "//sandbox/mac:seatbelt" ] | 236 deps += [ "//sandbox/mac:seatbelt" ] |
| 218 } | 237 } |
| 219 | 238 |
| 220 if (is_fuchsia) { | 239 if (is_fuchsia) { |
| 221 sources -= [ | 240 sources -= [ |
| 222 # No AF_UNIX domain sockets on Fuchsia. | 241 # No AF_UNIX domain sockets on Fuchsia. |
| 223 "sync_socket_unittest.cc", | 242 "sync_socket_unittest.cc", |
| 224 ] | 243 ] |
| 225 } | 244 } |
| 245 |
| 246 if (!is_nacl_nonsfi) { |
| 247 sources += [ |
| 248 "ipc_message_repeated_field_utils_unittest.cc", |
| 249 ] |
| 250 } |
| 226 } | 251 } |
| 227 | 252 |
| 228 test("ipc_perftests") { | 253 test("ipc_perftests") { |
| 229 sources = [ | 254 sources = [ |
| 230 "ipc_mojo_perftest.cc", | 255 "ipc_mojo_perftest.cc", |
| 231 "run_all_perftests.cc", | 256 "run_all_perftests.cc", |
| 232 ] | 257 ] |
| 233 | 258 |
| 234 deps = [ | 259 deps = [ |
| 235 ":ipc", | 260 ":ipc", |
| (...skipping 25 matching lines...) Expand all Loading... |
| 261 ":ipc", | 286 ":ipc", |
| 262 ] | 287 ] |
| 263 deps = [ | 288 deps = [ |
| 264 "//base", | 289 "//base", |
| 265 "//base/test:test_support", | 290 "//base/test:test_support", |
| 266 "//mojo/edk/test:test_support", | 291 "//mojo/edk/test:test_support", |
| 267 "//testing/gtest", | 292 "//testing/gtest", |
| 268 ] | 293 ] |
| 269 } | 294 } |
| 270 } | 295 } |
| OLD | NEW |