summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/test/BUILD.gn2
-rw-r--r--chrome/test/data/nacl/BUILD.gn6
-rw-r--r--components/nacl/loader/BUILD.gn3
-rw-r--r--extensions/shell/BUILD.gn5
-rw-r--r--ppapi/BUILD.gn86
-rw-r--r--ppapi/native_client/BUILD.gn4
-rw-r--r--ppapi/tests/extensions/BUILD.gn4
7 files changed, 65 insertions, 45 deletions
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
index e3eb827..a373a7f 100644
--- a/chrome/test/BUILD.gn
+++ b/chrome/test/BUILD.gn
@@ -987,7 +987,7 @@ if (!is_android) {
}
if (is_win || is_linux) {
sources += [ "../browser/nacl_host/test/nacl_gdb_browsertest.cc" ]
- deps += [ "//chrome/browser/nacl_host/test:mock_nacl_gdb" ]
+ data_deps += [ "//chrome/browser/nacl_host/test:mock_nacl_gdb" ]
}
if (is_win) {
# TODO(halyavin) NaCl on Windows can't open debug stub socket in
diff --git a/chrome/test/data/nacl/BUILD.gn b/chrome/test/data/nacl/BUILD.gn
index a47619d..beb8da5 100644
--- a/chrome/test/data/nacl/BUILD.gn
+++ b/chrome/test/data/nacl/BUILD.gn
@@ -9,7 +9,7 @@ group("nacl") {
newlib = "//build/toolchain/nacl:clang_newlib_${target_cpu}"
glibc = "//build/toolchain/nacl:glibc_${target_cpu}"
pnacl = "//build/toolchain/nacl:newlib_pnacl"
- deps = [
+ data_deps = [
":exit_status_test($glibc)",
":exit_status_test($newlib)",
":exit_status_test($pnacl)",
@@ -74,13 +74,13 @@ group("nacl") {
]
if (is_linux) {
nonsfi = "//build/toolchain/nacl:newlib_pnacl_nonsfi"
- deps += [
+ data_deps += [
":irt_exception_test($nonsfi)",
":irt_manifest_file($nonsfi)",
":shared_test_files($nonsfi)",
]
if (is_clang) {
- deps += [ ":nonsfi_libc_free" ]
+ data_deps += [ ":nonsfi_libc_free" ]
}
}
}
diff --git a/components/nacl/loader/BUILD.gn b/components/nacl/loader/BUILD.gn
index db7a71d..af73428 100644
--- a/components/nacl/loader/BUILD.gn
+++ b/components/nacl/loader/BUILD.gn
@@ -140,7 +140,7 @@ if (is_linux) {
}
group("helper_nonsfi") {
- deps = [
+ data_deps = [
":nacl_helper_nonsfi_copy(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
]
}
@@ -159,6 +159,7 @@ if (is_linux) {
testonly = true
data_deps = [
":helper_nonsfi_unittests",
+ ":nacl_helper_nonsfi_unittests_main_copy(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
]
}
}
diff --git a/extensions/shell/BUILD.gn b/extensions/shell/BUILD.gn
index 0f8af6e..8cb0dd3 100644
--- a/extensions/shell/BUILD.gn
+++ b/extensions/shell/BUILD.gn
@@ -104,7 +104,10 @@ source_set("app_shell_lib") {
]
if (is_linux) {
- deps += [ "//components/nacl/loader:nacl_helper" ]
+ deps += [
+ "//components/nacl/loader:helper_nonsfi",
+ "//components/nacl/loader:nacl_helper",
+ ]
}
}
diff --git a/ppapi/BUILD.gn b/ppapi/BUILD.gn
index 842dbbd..182287f 100644
--- a/ppapi/BUILD.gn
+++ b/ppapi/BUILD.gn
@@ -193,6 +193,8 @@ source_set("ppapi_gles2_lib") {
if (enable_nacl) {
if (is_nacl) {
shared_library("ppapi_cpp_lib_shared") {
+ output_name = "libppapi_cpp"
+
# When using gcc, we hide all symbols by default, but that breaks at
# link time as the test executable requires symbols defined in the
# shared library.
@@ -211,7 +213,8 @@ if (enable_nacl) {
]
}
- executable("ppapi_nacl_tests") {
+ executable("ppapi_nacl_tests_nexe") {
+ output_name = "ppapi_nacl_tests"
include_dirs = [ "lib/gl/include" ]
sources = ppapi_sources.test_common_source_files +
ppapi_sources.test_nacl_source_files
@@ -235,7 +238,7 @@ if (enable_nacl) {
action("translate_pexe_to_nexe") {
# We specify the toolchain explicitly because in the Non-SFI case, we
# still want to use the pexe built using the newlib_pnacl toolchain.
- tests = ":ppapi_nacl_tests(//build/toolchain/nacl:newlib_pnacl)"
+ tests = ":ppapi_nacl_tests_nexe(//build/toolchain/nacl:newlib_pnacl)"
pexe = get_label_info(tests, "root_out_dir") + "/ppapi_nacl_tests.pexe"
nexe = "${root_out_dir}/ppapi_nacl_tests.nexe"
@@ -295,26 +298,29 @@ if (enable_nacl) {
}
}
- copy("nacl_tests_copy") {
+ copy("ppapi_nacl_tests_copy") {
sources = [
"${root_out_dir}/ppapi_nacl_tests.nexe",
]
# The CPU names used in tests/ppapi_nacl_tests_newlib.nmf
# are the ones used in GYP (x32 for x86).
- if (current_cpu == "pnacl") {
- suffix = "pnacl"
+ if (target_cpu == "x86" ||
+ (is_nacl_nonsfi && (target_cpu == "x86" || target_cpu == "x64"))) {
+ nmf_cpu = "x32"
} else {
- if (target_cpu == "x86") {
- nmf_cpu = "x32"
- } else {
- nmf_cpu = target_cpu
- }
- if (is_nacl_glibc) {
- suffix = "glibc_${nmf_cpu}"
+ nmf_cpu = target_cpu
+ }
+ if (current_cpu == "pnacl") {
+ if (is_nacl_nonsfi) {
+ suffix = "pnacl_newlib_${nmf_cpu}_nonsfi"
} else {
- suffix = "newlib_${nmf_cpu}"
+ suffix = "pnacl_newlib_${nmf_cpu}"
}
+ } else if (is_nacl_glibc) {
+ suffix = "glibc_${nmf_cpu}"
+ } else {
+ suffix = "newlib_${nmf_cpu}"
}
outputs = [
"${root_build_dir}/{{source_name_part}}_${suffix}.nexe",
@@ -325,31 +331,41 @@ if (enable_nacl) {
]
} else {
deps = [
- ":ppapi_nacl_tests",
+ ":ppapi_nacl_tests_nexe",
]
}
}
- generate_nmf("ppapi_nacl_tests_nmf") {
- if (is_nacl_glibc) {
- nmf = "${root_build_dir}/ppapi_nacl_tests_glibc.nmf"
- stage_dependencies = root_build_dir
- } else if (current_cpu == "pnacl") {
- nmf = "${root_build_dir}/ppapi_nacl_tests_pnacl.nmf"
- } else {
- nmf = "${root_build_dir}/ppapi_nacl_tests_newlib.nmf"
+ if (is_nacl_nonsfi) {
+ generate_nonsfi_test_nmf("ppapi_nacl_tests_nmf") {
+ nmf = "${root_build_dir}/ppapi_nacl_tests_pnacl_nonsfi.nmf"
+ files = get_target_outputs(":ppapi_nacl_tests_copy")
+ executable = files[0]
+ deps = [
+ ":ppapi_nacl_tests_copy",
+ ]
+ }
+ } else {
+ generate_nmf("ppapi_nacl_tests_nmf") {
+ if (is_nacl_glibc) {
+ nmf = "${root_build_dir}/ppapi_nacl_tests_glibc.nmf"
+ stage_dependencies = root_build_dir
+ } else if (current_cpu == "pnacl") {
+ nmf = "${root_build_dir}/ppapi_nacl_tests_pnacl.nmf"
+ } else {
+ nmf = "${root_build_dir}/ppapi_nacl_tests_newlib.nmf"
+ }
+ executables = get_target_outputs(":ppapi_nacl_tests_copy")
+ deps = [
+ ":ppapi_nacl_tests_copy",
+ ]
}
- executables = get_target_outputs(":nacl_tests_copy")
- deps = [
- ":nacl_tests_copy",
- ]
}
- generate_nonsfi_test_nmf("ppapi_nacl_tests_pnacl_nonsfi_nmf") {
- nmf = "${root_build_dir}/ppapi_nacl_tests_pnacl_nonsfi.nmf"
- executable = "${root_out_dir}/ppapi_nacl_tests.nexe"
- deps = [
- ":translate_pexe_to_nexe",
+ group("ppapi_nacl_tests") {
+ data_deps = [
+ ":ppapi_nacl_tests_copy",
+ ":ppapi_nacl_tests_nmf",
]
}
}
@@ -357,13 +373,13 @@ if (enable_nacl) {
group("ppapi_nacl_tests_all") {
data_deps = [
":copy_test_files",
- ":nacl_tests_copy(//build/toolchain/nacl:clang_newlib_${target_cpu})",
- ":ppapi_nacl_tests_nmf(//build/toolchain/nacl:glibc_${target_cpu})",
+ ":ppapi_nacl_tests_copy(//build/toolchain/nacl:clang_newlib_${target_cpu})",
+ ":ppapi_nacl_tests(//build/toolchain/nacl:glibc_${target_cpu})",
]
if (enable_pnacl) {
data_deps += [
- ":ppapi_nacl_tests_nmf(//build/toolchain/nacl:newlib_pnacl)",
- ":ppapi_nacl_tests_pnacl_nonsfi_nmf(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
+ ":ppapi_nacl_tests(//build/toolchain/nacl:newlib_pnacl)",
+ ":ppapi_nacl_tests(//build/toolchain/nacl:newlib_pnacl_nonsfi)",
]
}
}
diff --git a/ppapi/native_client/BUILD.gn b/ppapi/native_client/BUILD.gn
index 374d970..6a358e1 100644
--- a/ppapi/native_client/BUILD.gn
+++ b/ppapi/native_client/BUILD.gn
@@ -96,14 +96,14 @@ if (is_nacl) {
}
group("irt") {
- public_deps = [
+ data_deps = [
":nacl_irt_debug(//build/toolchain/nacl:irt_${target_cpu})",
":nacl_irt_debuglink(//build/toolchain/nacl:irt_${target_cpu})",
]
# On 32-bit Windows, we also ship the 64-bit IRT.
if (is_win && target_cpu == "x86") {
- public_deps += [
+ data_deps += [
":nacl_irt_debug(//build/toolchain/nacl:irt_x64)",
":nacl_irt_debuglink(//build/toolchain/nacl:irt_x64)",
]
diff --git a/ppapi/tests/extensions/BUILD.gn b/ppapi/tests/extensions/BUILD.gn
index 741ba71..615a103 100644
--- a/ppapi/tests/extensions/BUILD.gn
+++ b/ppapi/tests/extensions/BUILD.gn
@@ -8,7 +8,7 @@ import("//ppapi/native_client/nacl_test_data.gni")
group("extensions") {
newlib = "//build/toolchain/nacl:clang_newlib_${target_cpu}"
pnacl = "//build/toolchain/nacl:newlib_pnacl"
- deps = [
+ data_deps = [
":ppapi_tests_extensions_background_keepalive($newlib)",
":ppapi_tests_extensions_load_unload($newlib)",
":ppapi_tests_extensions_media_galleries($newlib)",
@@ -21,7 +21,7 @@ group("extensions") {
]
if ((target_cpu == "x86" || target_cpu == "x64") && is_linux) {
nonsfi = "//build/toolchain/nacl:newlib_pnacl_nonsfi"
- deps += [ ":ppapi_tests_extensions_packaged_app($nonsfi)" ]
+ data_deps += [ ":ppapi_tests_extensions_packaged_app($nonsfi)" ]
}
}