blob: ebd6417a4d7be67e1bff4118ebd8577f10385d63 [file] [log] [blame]
brettwf4b4a4282015-12-16 00:41:131# Copyright 2015 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
Dirk Prankeccc0c362017-09-28 22:15:115import("//components/nacl/features.gni")
brettwf4b4a4282015-12-16 00:41:136
7assert(enable_nacl)
8
brettwe664a262016-07-21 23:48:369static_library("browser") {
brettwf4b4a4282015-12-16 00:41:1310 sources = [
11 "bad_message.cc",
12 "bad_message.h",
brettwf4b4a4282015-12-16 00:41:1313 "nacl_browser.cc",
14 "nacl_browser.h",
15 "nacl_file_host.cc",
16 "nacl_file_host.h",
17 "nacl_host_message_filter.cc",
18 "nacl_host_message_filter.h",
19 "nacl_process_host.cc",
20 "nacl_process_host.h",
21 "nacl_validation_cache.cc",
22 "nacl_validation_cache.h",
23 "pnacl_host.cc",
24 "pnacl_host.h",
25 "pnacl_translation_cache.cc",
26 "pnacl_translation_cache.h",
27 ]
28
29 deps = [
30 "//base",
31 "//base/third_party/dynamic_annotations",
Yuta Hijikataba103462020-11-30 08:33:3532 "//build:chromeos_buildflags",
brettwf4b4a4282015-12-16 00:41:1333 "//components/nacl/common",
Scott Violet9ae82892018-03-01 18:38:1234 "//components/nacl/common:buildflags",
brettwf4b4a4282015-12-16 00:41:1335 "//components/nacl/common:debug_exception_handler",
36 "//components/url_formatter",
37 "//content/public/browser",
38 "//content/public/common",
brettwf4b4a4282015-12-16 00:41:1339 "//native_client/src/trusted/service_runtime:sel_main_chrome",
40 "//net",
41 "//ppapi/host",
42 "//ppapi/proxy:ipc",
43 "//ppapi/shared_impl",
44 ]
45
rockot38e46dd2017-03-24 16:55:1346 public_deps = [
47 "//ipc",
Ken Rockot543f5e32018-02-04 02:13:5048 "//services/service_manager/public/mojom",
rockot38e46dd2017-03-24 16:55:1349 ]
50
brettwf4b4a4282015-12-16 00:41:1351 data_deps = []
52
Sylvain Defresne17327132020-10-06 16:50:1953 if (is_win) {
54 sources += [
55 "nacl_broker_host_win.cc",
56 "nacl_broker_host_win.h",
57 "nacl_broker_service_win.cc",
58 "nacl_broker_service_win.h",
59 ]
60 }
61
Sean McAllister8ccdb7642020-07-30 20:05:5262 if (is_linux || is_chromeos) {
brettwf4b4a4282015-12-16 00:41:1363 sources += [
64 "../zygote/nacl_fork_delegate_linux.cc",
65 "../zygote/nacl_fork_delegate_linux.h",
66 ]
67
68 deps += [
69 "//components/nacl/loader:nacl_helper_integration",
70 "//sandbox/linux:sandbox_services",
71 "//sandbox/linux:suid_sandbox_client",
72 ]
73
milko.leporis3de038d2016-08-18 09:59:3774 if (enable_nacl_nonsfi) {
75 data_deps += [ "//components/nacl/loader:helper_nonsfi" ]
76 }
brettwf4b4a4282015-12-16 00:41:1377 }
mcgrathra681f792016-01-11 20:48:1078
79 if (is_win && current_cpu == "x86") {
80 data_deps += [ "//components/nacl/broker:nacl64" ]
81 }
brettwf4b4a4282015-12-16 00:41:1382}
brucedawson5982933b2016-05-06 19:03:0283
84source_set("unit_tests") {
85 testonly = true
86 sources = [
87 "nacl_file_host_unittest.cc",
88 "nacl_process_host_unittest.cc",
89 "nacl_validation_cache_unittest.cc",
90 "pnacl_host_unittest.cc",
91 "pnacl_translation_cache_unittest.cc",
92 "test_nacl_browser_delegate.cc",
thakisb8590c92017-03-23 18:14:5393 "test_nacl_browser_delegate.h",
brucedawson5982933b2016-05-06 19:03:0294 ]
95
96 deps = [
97 ":browser",
98 "//base",
99 "//components/nacl/common",
100 "//content/test:test_support",
101 "//net:test_support",
102 ]
103
Sean McAllister8ccdb7642020-07-30 20:05:52104 if (is_linux || is_chromeos) {
brucedawson5982933b2016-05-06 19:03:02105 sources += [ "../zygote/nacl_fork_delegate_linux_unittest.cc" ]
106 }
107}