1# Copyright 2015 The Chromium Authors 2# Use of this source code is governed by a BSD-style license that can be 3# found in the LICENSE file. 4 5import("//components/nacl/features.gni") 6 7assert(enable_nacl) 8 9static_library("browser") { 10 sources = [ 11 "bad_message.cc", 12 "bad_message.h", 13 "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", 32 "//build:chromeos_buildflags", 33 "//components/nacl/common", 34 "//components/nacl/common:buildflags", 35 "//components/url_formatter", 36 "//content/public/browser", 37 "//content/public/common", 38 "//net", 39 "//ppapi/host", 40 "//ppapi/proxy:ipc", 41 "//ppapi/shared_impl", 42 ] 43 44 public_deps = [ 45 "//ipc", 46 "//services/service_manager/public/mojom", 47 ] 48 49 data_deps = [] 50 51 if (is_linux || is_chromeos) { 52 sources += [ 53 "../zygote/nacl_fork_delegate_linux.cc", 54 "../zygote/nacl_fork_delegate_linux.h", 55 ] 56 57 deps += [ 58 "//sandbox/linux:sandbox_services", 59 "//sandbox/linux:suid_sandbox_client", 60 ] 61 62 if (target_cpu != "arm64") { 63 deps += [ "//components/nacl/loader:nacl_helper_integration" ] 64 } else { 65 deps += [ "//components/nacl/loader:nacl_helper" ] 66 } 67 } 68} 69 70source_set("unit_tests") { 71 testonly = true 72 sources = [ 73 "nacl_file_host_unittest.cc", 74 "nacl_validation_cache_unittest.cc", 75 "pnacl_host_unittest.cc", 76 "pnacl_translation_cache_unittest.cc", 77 "test_nacl_browser_delegate.cc", 78 "test_nacl_browser_delegate.h", 79 ] 80 81 deps = [ 82 ":browser", 83 "//base", 84 "//components/nacl/common", 85 "//content/test:test_support", 86 "//net:test_support", 87 ] 88 89 if (is_linux || is_chromeos) { 90 sources += [ "../zygote/nacl_fork_delegate_linux_unittest.cc" ] 91 } 92} 93