| Index: components/nacl/BUILD.gn
|
| diff --git a/components/nacl/BUILD.gn b/components/nacl/BUILD.gn
|
| index ad200c93455c90e2684ee1994a2634af6205916d..209ff02d017d9c409276c115e7fa1928ced32ec1 100644
|
| --- a/components/nacl/BUILD.gn
|
| +++ b/components/nacl/BUILD.gn
|
| @@ -180,6 +180,20 @@ if (enable_nacl) {
|
| "//ppapi/c",
|
| "//testing/gtest",
|
| ]
|
| +
|
| + if (is_nacl_nonsfi) {
|
| + sources += [
|
| + # TODO(hamaji): Currently, we build them twice. Stop building
|
| + # them for components_unittests. See crbug.com/364751
|
| + "loader/nonsfi/nonsfi_sandbox_sigsys_unittest.cc",
|
| + "loader/nonsfi/nonsfi_sandbox_unittest.cc",
|
| + ]
|
| +
|
| + deps += [
|
| + ":nacl_linux",
|
| + "//sandbox/linux:sandbox_linux_test_utils",
|
| + ]
|
| + }
|
| }
|
|
|
| if (is_linux) {
|
| @@ -248,6 +262,30 @@ if (enable_nacl) {
|
| defines += [ "USE_SECCOMP_BPF" ]
|
| }
|
| }
|
| +
|
| + test("nacl_helper_nonsfi_unittests") {
|
| + sources = [
|
| + "loader/nonsfi/nacl_helper_nonsfi_unittests.cc",
|
| + ]
|
| + deps = [
|
| + "//base",
|
| + "//base/test:test_launcher_nacl_nonsfi",
|
| + ]
|
| + }
|
| +
|
| + group("helper_nonsfi") {
|
| + deps = [
|
| + ":nacl_helper_nonsfi_copy(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
|
| + ]
|
| + }
|
| +
|
| + group("helper_nonsfi_unittests") {
|
| + testonly = true
|
| + deps = [
|
| + ":nacl_helper_nonsfi_unittests",
|
| + ":nacl_helper_nonsfi_unittests_main_copy(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
|
| + ]
|
| + }
|
| }
|
|
|
| if (is_nacl_nonsfi) {
|
| @@ -313,12 +351,39 @@ if (enable_nacl) {
|
| ":nacl_helper_nonsfi_nexe",
|
| ]
|
| }
|
| - }
|
|
|
| - group("helper_nonsfi") {
|
| - deps = [
|
| - ":nacl_helper_nonsfi_copy(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
|
| - ]
|
| + test("nacl_helper_nonsfi_unittests_main") {
|
| + sources = [
|
| + "loader/nonsfi/nonsfi_sandbox_sigsys_unittest.cc",
|
| + "loader/nonsfi/nonsfi_sandbox_unittest.cc",
|
| + "loader/nonsfi/run_all_unittests.cc",
|
| + ]
|
| + deps = [
|
| + ":nacl_helper_nonsfi_sandbox",
|
| + "//base",
|
| + "//base/test:test_support_nonsfi",
|
| + "//content",
|
| + "//native_client/src/nonsfi/irt:nacl_sys_private",
|
| + "//native_client/src/untrusted/nacl:nacl",
|
| + "//sandbox/linux:sandbox",
|
| + "//sandbox/linux:sandbox_linux_test_utils",
|
| + "//sandbox/linux:sandbox_services_headers",
|
| + "//testing/gtest",
|
| + ]
|
| + }
|
| +
|
| + copy("nacl_helper_nonsfi_unittests_main_copy") {
|
| + testonly = true
|
| + sources = [
|
| + "${root_out_dir}/nacl_helper_nonsfi_unittests_main",
|
| + ]
|
| + outputs = [
|
| + "${root_build_dir}/{{source_file_part}}",
|
| + ]
|
| + deps = [
|
| + ":nacl_helper_nonsfi_unittests_main",
|
| + ]
|
| + }
|
| }
|
| }
|
|
|
|
|