[gyp] move build targets for tests to gypfiles.

Bug: v8:7335
Change-Id: I6610bba00ff558de5826934c326fc2873c91a1a3
Reviewed-on: https://chromium-review.googlesource.com/890742
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50944}
This commit is contained in:
Yang Guo 2018-01-29 11:05:24 +01:00 committed by Commit Bot
parent ff05633408
commit b1d09bf6c5
14 changed files with 606 additions and 613 deletions

View File

@ -279,10 +279,11 @@ GYPFILES = third_party/icu/icu.gypi third_party/icu/icu.gyp \
gypfiles/shim_headers.gypi gypfiles/features.gypi \
gypfiles/standalone.gypi \
gypfiles/toolchain.gypi gypfiles/all.gyp gypfiles/mac/asan.gyp \
gypfiles/cctest.gyp test/fuzzer/fuzzer.gyp \
test/unittests/unittests.gyp gypfiles/v8.gyp \
gypfiles/parser-shell.gyp testing/gmock.gyp testing/gtest.gyp \
gypfiles/samples.gyp gypfiles/v8vtune.gyp gypfiles/d8.gyp
gypfiles/cctest.gyp gypfiles/fuzzer.gyp \
gypfiles/unittests.gyp gypfiles/v8.gyp \
gypfiles/parser-shell.gyp gypfiles/gmock.gyp gypfiles/gtest.gyp \
gypfiles/samples.gyp gypfiles/v8vtune.gyp gypfiles/d8.gyp \
gypfiles/inspector-test.gyp gypfiles/mkgrokdump.gyp
# Generates all combinations of ARCHES and MODES, e.g. "ia32.release".
BUILDS = $(foreach mode,$(MODES),$(addsuffix .$(mode),$(ARCHES)))

View File

@ -8,9 +8,9 @@
'target_name': 'All',
'type': 'none',
'dependencies': [
'../gypfiles/d8.gyp:d8',
'../test/inspector/inspector.gyp:*',
'../test/mkgrokdump/mkgrokdump.gyp:*',
'd8.gyp:d8',
'inspector-test.gyp:*',
'mkgrokdump.gyp:*',
],
'conditions': [
['component!="shared_library"', {
@ -23,8 +23,8 @@
'dependencies': [
'samples.gyp:*',
'cctest.gyp:*',
'../test/fuzzer/fuzzer.gyp:*',
'../test/unittests/unittests.gyp:*',
'fuzzer.gyp:*',
'unittests.gyp:*',
],
}],
['test_isolation_mode != "noop"', {

View File

@ -6,7 +6,7 @@
'variables': {
'v8_code': 1,
},
'includes': ['../../gypfiles/toolchain.gypi', '../../gypfiles/features.gypi'],
'includes': ['toolchain.gypi', 'features.gypi'],
'targets': [
{
'target_name': 'v8_simple_json_fuzzer',
@ -15,24 +15,24 @@
'json_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'json_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'json.cc',
'../test/fuzzer/json.cc',
],
},
{
@ -42,24 +42,24 @@
'parser_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'parser_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'parser.cc',
'../test/fuzzer/parser.cc',
],
},
{
@ -69,25 +69,25 @@
'regexp_builtins_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'regexp_builtins_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'regexp-builtins.cc',
'regexp_builtins/mjsunit.js.h',
'../test/fuzzer/regexp-builtins.cc',
'../test/fuzzer/regexp_builtins/mjsunit.js.h',
],
},
{
@ -97,24 +97,24 @@
'regexp_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'regexp_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'regexp.cc',
'../test/fuzzer/regexp.cc',
],
},
{
@ -124,27 +124,27 @@
'multi_return_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'multi_return_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'../compiler/c-signature.h',
'../compiler/call-helper.h',
'../compiler/raw-machine-assembler-tester.h',
'multi-return.cc',
'../test/cctest/compiler/c-signature.h',
'../test/cctest/compiler/call-helper.h',
'../test/cctest/compiler/raw-machine-assembler-tester.h',
'../test/fuzzer/multi-return.cc',
],
},
{
@ -154,28 +154,28 @@
'wasm_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -185,28 +185,28 @@
'wasm_async_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_async_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-async.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-async.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -216,29 +216,29 @@
'wasm_call_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_call_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-call.cc',
'../common/wasm/test-signatures.h',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-call.cc',
'../test/common/wasm/test-signatures.h',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -248,29 +248,29 @@
'wasm_code_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_code_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-code.cc',
'../common/wasm/test-signatures.h',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-code.cc',
'../test/common/wasm/test-signatures.h',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -280,29 +280,29 @@
'wasm_compile_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_compile_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-compile.cc',
'../common/wasm/test-signatures.h',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-compile.cc',
'../test/common/wasm/test-signatures.h',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -312,28 +312,28 @@
'wasm_data_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_data_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-data-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-data-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -343,28 +343,28 @@
'wasm_function_sigs_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_function_sigs_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-function-sigs-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-function-sigs-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -374,28 +374,28 @@
'wasm_globals_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_globals_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-globals-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-globals-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -405,28 +405,28 @@
'wasm_imports_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_imports_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-imports-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-imports-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -436,28 +436,28 @@
'wasm_memory_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_memory_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-memory-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-memory-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -467,28 +467,28 @@
'wasm_names_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_names_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-names-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-names-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
@ -498,44 +498,44 @@
'wasm_types_section_fuzzer_lib',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer.cc',
'../test/fuzzer/fuzzer.cc',
],
},
{
'target_name': 'wasm_types_section_fuzzer_lib',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8_libplatform',
'fuzzer_support',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'wasm-types-section.cc',
'../common/wasm/wasm-module-runner.cc',
'../common/wasm/wasm-module-runner.h',
'wasm-fuzzer-common.cc',
'wasm-fuzzer-common.h',
'../test/fuzzer/wasm-types-section.cc',
'../test/common/wasm/wasm-module-runner.cc',
'../test/common/wasm/wasm-module-runner.h',
'../test/fuzzer/wasm-fuzzer-common.cc',
'../test/fuzzer/wasm-fuzzer-common.h',
],
},
{
'target_name': 'fuzzer_support',
'type': 'static_library',
'dependencies': [
'../../gypfiles/v8.gyp:v8',
'../../gypfiles/v8.gyp:v8_libbase',
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8',
'v8.gyp:v8_libbase',
'v8.gyp:v8_libplatform',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'fuzzer-support.cc',
'fuzzer-support.h',
'../test/fuzzer/fuzzer-support.cc',
'../test/fuzzer/fuzzer-support.h',
],
'conditions': [
['v8_enable_i18n_support==1', {
@ -561,10 +561,10 @@
'v8_simple_wasm_fuzzer',
],
'includes': [
'../../gypfiles/isolate.gypi',
'isolate.gypi',
],
'sources': [
'fuzzer.isolate',
'../test/fuzzer/fuzzer.isolate',
],
},
],

72
gypfiles/gmock.gyp Normal file
View File

@ -0,0 +1,72 @@
# Copyright 2014 the V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
{
'targets': [
{
'target_name': 'gmock',
'type': 'static_library',
'dependencies': [
'gtest.gyp:gtest',
],
'sources': [
# Sources based on files in r173 of gmock.
'../testing/gmock/include/gmock/gmock-actions.h',
'../testing/gmock/include/gmock/gmock-cardinalities.h',
'../testing/gmock/include/gmock/gmock-generated-actions.h',
'../testing/gmock/include/gmock/gmock-generated-function-mockers.h',
'../testing/gmock/include/gmock/gmock-generated-matchers.h',
'../testing/gmock/include/gmock/gmock-generated-nice-strict.h',
'../testing/gmock/include/gmock/gmock-matchers.h',
'../testing/gmock/include/gmock/gmock-spec-builders.h',
'../testing/gmock/include/gmock/gmock.h',
'../testing/gmock/include/gmock/internal/gmock-generated-internal-utils.h',
'../testing/gmock/include/gmock/internal/gmock-internal-utils.h',
'../testing/gmock/include/gmock/internal/gmock-port.h',
'../testing/gmock/src/gmock-all.cc',
'../testing/gmock/src/gmock-cardinalities.cc',
'../testing/gmock/src/gmock-internal-utils.cc',
'../testing/gmock/src/gmock-matchers.cc',
'../testing/gmock/src/gmock-spec-builders.cc',
'../testing/gmock/src/gmock.cc',
'../testing/gmock-support.h', # gMock helpers
'../testing/gmock_custom/gmock/internal/custom/gmock-port.h',
],
'sources!': [
'../testing/gmock/src/gmock-all.cc', # Not needed by our build.
],
'include_dirs': [
'../testing/gmock_custom',
'../testing/gmock',
'../testing/gmock/include',
],
'all_dependent_settings': {
'include_dirs': [
'../testing/gmock_custom',
'../testing/gmock/include', # So that gmock headers can find themselves.
],
},
'export_dependent_settings': [
'gtest.gyp:gtest',
],
'conditions': [
['want_separate_host_toolset==1', {
'toolsets': ['host', 'target'],
}, {
'toolsets': ['target'],
}],
],
},
{
'target_name': 'gmock_main',
'type': 'static_library',
'dependencies': [
'gmock',
],
'sources': [
'../testing/gmock/src/gmock_main.cc',
],
},
],
}

View File

@ -9,42 +9,42 @@
'toolsets': ['host', 'target'],
'type': 'static_library',
'sources': [
'gtest/include/gtest/gtest-death-test.h',
'gtest/include/gtest/gtest-message.h',
'gtest/include/gtest/gtest-param-test.h',
'gtest/include/gtest/gtest-printers.h',
'gtest/include/gtest/gtest-spi.h',
'gtest/include/gtest/gtest-test-part.h',
'gtest/include/gtest/gtest-typed-test.h',
'gtest/include/gtest/gtest.h',
'gtest/include/gtest/gtest_pred_impl.h',
'gtest/include/gtest/internal/gtest-death-test-internal.h',
'gtest/include/gtest/internal/gtest-filepath.h',
'gtest/include/gtest/internal/gtest-internal.h',
'gtest/include/gtest/internal/gtest-linked_ptr.h',
'gtest/include/gtest/internal/gtest-param-util-generated.h',
'gtest/include/gtest/internal/gtest-param-util.h',
'gtest/include/gtest/internal/gtest-port.h',
'gtest/include/gtest/internal/gtest-string.h',
'gtest/include/gtest/internal/gtest-tuple.h',
'gtest/include/gtest/internal/gtest-type-util.h',
'gtest/src/gtest-all.cc',
'gtest/src/gtest-death-test.cc',
'gtest/src/gtest-filepath.cc',
'gtest/src/gtest-internal-inl.h',
'gtest/src/gtest-port.cc',
'gtest/src/gtest-printers.cc',
'gtest/src/gtest-test-part.cc',
'gtest/src/gtest-typed-test.cc',
'gtest/src/gtest.cc',
'gtest-support.h',
'../testing/gtest/include/gtest/gtest-death-test.h',
'../testing/gtest/include/gtest/gtest-message.h',
'../testing/gtest/include/gtest/gtest-param-test.h',
'../testing/gtest/include/gtest/gtest-printers.h',
'../testing/gtest/include/gtest/gtest-spi.h',
'../testing/gtest/include/gtest/gtest-test-part.h',
'../testing/gtest/include/gtest/gtest-typed-test.h',
'../testing/gtest/include/gtest/gtest.h',
'../testing/gtest/include/gtest/gtest_pred_impl.h',
'../testing/gtest/include/gtest/internal/gtest-death-test-internal.h',
'../testing/gtest/include/gtest/internal/gtest-filepath.h',
'../testing/gtest/include/gtest/internal/gtest-internal.h',
'../testing/gtest/include/gtest/internal/gtest-linked_ptr.h',
'../testing/gtest/include/gtest/internal/gtest-param-util-generated.h',
'../testing/gtest/include/gtest/internal/gtest-param-util.h',
'../testing/gtest/include/gtest/internal/gtest-port.h',
'../testing/gtest/include/gtest/internal/gtest-string.h',
'../testing/gtest/include/gtest/internal/gtest-tuple.h',
'../testing/gtest/include/gtest/internal/gtest-type-util.h',
'../testing/gtest/src/gtest-all.cc',
'../testing/gtest/src/gtest-death-test.cc',
'../testing/gtest/src/gtest-filepath.cc',
'../testing/gtest/src/gtest-internal-inl.h',
'../testing/gtest/src/gtest-port.cc',
'../testing/gtest/src/gtest-printers.cc',
'../testing/gtest/src/gtest-test-part.cc',
'../testing/gtest/src/gtest-typed-test.cc',
'../testing/gtest/src/gtest.cc',
'../testing/gtest-support.h',
],
'sources!': [
'gtest/src/gtest-all.cc', # Not needed by our build.
'../testing/gtest/src/gtest-all.cc', # Not needed by our build.
],
'include_dirs': [
'gtest',
'gtest/include',
'../testing/gtest',
'../testing/gtest/include',
],
'dependencies': [
'gtest_prod',
@ -78,7 +78,7 @@
'UNIT_TEST',
],
'include_dirs': [
'gtest/include', # So that gtest headers can find themselves.
'../testing/gtest/include', # So that gtest headers can find themselves.
],
'target_conditions': [
['_type=="executable"', {
@ -107,7 +107,7 @@
'gtest',
],
'sources': [
'gtest/src/gtest_main.cc',
'../testing/gtest/src/gtest_main.cc',
],
},
{
@ -115,7 +115,7 @@
'toolsets': ['host', 'target'],
'type': 'none',
'sources': [
'gtest/include/gtest/gtest_prod.h',
'../testing/gtest/include/gtest/gtest_prod.h',
],
},
],

View File

@ -6,25 +6,25 @@
'variables': {
'v8_code': 1,
},
'includes': ['../../gypfiles/toolchain.gypi', '../../gypfiles/features.gypi'],
'includes': ['toolchain.gypi', 'features.gypi'],
'targets': [
{
'target_name': 'inspector-test',
'type': 'executable',
'dependencies': [
'../../gypfiles/v8.gyp:v8_libplatform',
'../../gypfiles/v8.gyp:v8_libbase',
'../../gypfiles/v8.gyp:v8',
'v8.gyp:v8_libplatform',
'v8.gyp:v8_libbase',
'v8.gyp:v8',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'inspector-test.cc',
'isolate-data.cc',
'isolate-data.h',
'task-runner.cc',
'task-runner.h',
'../test/inspector/inspector-test.cc',
'../test/inspector/isolate-data.cc',
'../test/inspector/isolate-data.h',
'../test/inspector/task-runner.cc',
'../test/inspector/task-runner.h',
],
'conditions': [
['v8_enable_i18n_support==1', {
@ -46,10 +46,10 @@
'inspector-test',
],
'includes': [
'../../gypfiles/isolate.gypi',
'isolate.gypi',
],
'sources': [
'inspector.isolate',
'../test/inspector/inspector.isolate',
],
},
],

View File

@ -6,21 +6,21 @@
'variables': {
'v8_code': 1,
},
'includes': ['../../gypfiles/toolchain.gypi', '../../gypfiles/features.gypi'],
'includes': ['toolchain.gypi', 'features.gypi'],
'targets': [
{
'target_name': 'mkgrokdump',
'type': 'executable',
'dependencies': [
'../../gypfiles/v8.gyp:v8',
'../../gypfiles/v8.gyp:v8_libbase',
'../../gypfiles/v8.gyp:v8_libplatform',
'v8.gyp:v8',
'v8.gyp:v8_libbase',
'v8.gyp:v8_libplatform',
],
'include_dirs': [
'../..',
'..',
],
'sources': [
'mkgrokdump.cc',
'../test/mkgrokdump/mkgrokdump.cc',
],
},
],
@ -34,10 +34,10 @@
'mkgrokdump',
],
'includes': [
'../../gypfiles/isolate.gypi',
'isolate.gypi',
],
'sources': [
'mkgrokdump.isolate',
'../test/mkgrokdump/mkgrokdump.isolate',
],
},
],

306
gypfiles/unittests.gyp Normal file
View File

@ -0,0 +1,306 @@
# Copyright 2014 the V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# The sources are kept automatically in sync with BUILD.gn.
{
'variables': {
'v8_code': 1,
'unittests_sources': [
'../test/unittests/allocation-unittest.cc',
'../test/unittests/api/access-check-unittest.cc',
'../test/unittests/api/exception-unittest.cc',
'../test/unittests/api/interceptor-unittest.cc',
'../test/unittests/api/isolate-unittest.cc',
'../test/unittests/api/remote-object-unittest.cc',
'../test/unittests/api/v8-object-unittest.cc',
'../test/unittests/asmjs/asm-scanner-unittest.cc',
'../test/unittests/asmjs/asm-types-unittest.cc',
'../test/unittests/asmjs/switch-logic-unittest.cc',
'../test/unittests/base/atomic-utils-unittest.cc',
'../test/unittests/base/bits-unittest.cc',
'../test/unittests/base/cpu-unittest.cc',
'../test/unittests/base/division-by-constant-unittest.cc',
'../test/unittests/base/flags-unittest.cc',
'../test/unittests/base/functional-unittest.cc',
'../test/unittests/base/ieee754-unittest.cc',
'../test/unittests/base/logging-unittest.cc',
'../test/unittests/base/macros-unittest.cc',
'../test/unittests/base/iterator-unittest.cc',
'../test/unittests/base/ostreams-unittest.cc',
'../test/unittests/base/platform/condition-variable-unittest.cc',
'../test/unittests/base/platform/mutex-unittest.cc',
'../test/unittests/base/platform/platform-unittest.cc',
'../test/unittests/base/platform/semaphore-unittest.cc',
'../test/unittests/base/platform/time-unittest.cc',
'../test/unittests/base/sys-info-unittest.cc',
'../test/unittests/base/template-utils-unittest.cc',
'../test/unittests/base/utils/random-number-generator-unittest.cc',
'../test/unittests/bigint-unittest.cc',
'../test/unittests/cancelable-tasks-unittest.cc',
'../test/unittests/char-predicates-unittest.cc',
"../test/unittests/code-stub-assembler-unittest.cc",
"../test/unittests/code-stub-assembler-unittest.h",
'../test/unittests/compiler/branch-elimination-unittest.cc',
'../test/unittests/compiler/bytecode-analysis-unittest.cc',
'../test/unittests/compiler/checkpoint-elimination-unittest.cc',
"../test/unittests/compiler/code-assembler-unittest.cc",
"../test/unittests/compiler/code-assembler-unittest.h",
'../test/unittests/compiler/common-operator-reducer-unittest.cc',
'../test/unittests/compiler/common-operator-unittest.cc',
'../test/unittests/compiler/compiler-test-utils.h',
'../test/unittests/compiler/control-equivalence-unittest.cc',
'../test/unittests/compiler/control-flow-optimizer-unittest.cc',
'../test/unittests/compiler/dead-code-elimination-unittest.cc',
'../test/unittests/compiler/diamond-unittest.cc',
'../test/unittests/compiler/effect-control-linearizer-unittest.cc',
'../test/unittests/compiler/graph-reducer-unittest.cc',
'../test/unittests/compiler/graph-reducer-unittest.h',
'../test/unittests/compiler/graph-trimmer-unittest.cc',
'../test/unittests/compiler/graph-unittest.cc',
'../test/unittests/compiler/graph-unittest.h',
'../test/unittests/compiler/instruction-unittest.cc',
'../test/unittests/compiler/instruction-selector-unittest.cc',
'../test/unittests/compiler/instruction-selector-unittest.h',
'../test/unittests/compiler/instruction-sequence-unittest.cc',
'../test/unittests/compiler/instruction-sequence-unittest.h',
'../test/unittests/compiler/int64-lowering-unittest.cc',
'../test/unittests/compiler/js-builtin-reducer-unittest.cc',
'../test/unittests/compiler/js-create-lowering-unittest.cc',
'../test/unittests/compiler/js-intrinsic-lowering-unittest.cc',
'../test/unittests/compiler/js-operator-unittest.cc',
'../test/unittests/compiler/js-typed-lowering-unittest.cc',
'../test/unittests/compiler/linkage-tail-call-unittest.cc',
'../test/unittests/compiler/live-range-builder.h',
'../test/unittests/compiler/regalloc/live-range-unittest.cc',
'../test/unittests/compiler/load-elimination-unittest.cc',
'../test/unittests/compiler/loop-peeling-unittest.cc',
'../test/unittests/compiler/machine-operator-reducer-unittest.cc',
'../test/unittests/compiler/machine-operator-unittest.cc',
'../test/unittests/compiler/regalloc/move-optimizer-unittest.cc',
'../test/unittests/compiler/node-cache-unittest.cc',
'../test/unittests/compiler/node-matchers-unittest.cc',
'../test/unittests/compiler/node-properties-unittest.cc',
'../test/unittests/compiler/node-test-utils.cc',
'../test/unittests/compiler/node-test-utils.h',
'../test/unittests/compiler/node-unittest.cc',
'../test/unittests/compiler/opcodes-unittest.cc',
'../test/unittests/compiler/persistent-unittest.cc',
'../test/unittests/compiler/regalloc/register-allocator-unittest.cc',
'../test/unittests/compiler/schedule-unittest.cc',
'../test/unittests/compiler/scheduler-unittest.cc',
'../test/unittests/compiler/scheduler-rpo-unittest.cc',
'../test/unittests/compiler/simplified-lowering-unittest.cc',
'../test/unittests/compiler/simplified-operator-reducer-unittest.cc',
'../test/unittests/compiler/simplified-operator-unittest.cc',
'../test/unittests/compiler/state-values-utils-unittest.cc',
'../test/unittests/compiler/typed-optimization-unittest.cc',
'../test/unittests/compiler/typer-unittest.cc',
'../test/unittests/compiler/value-numbering-reducer-unittest.cc',
'../test/unittests/compiler/zone-stats-unittest.cc',
'../test/unittests/compiler-dispatcher/compiler-dispatcher-tracer-unittest.cc',
'../test/unittests/compiler-dispatcher/compiler-dispatcher-unittest.cc',
'../test/unittests/compiler-dispatcher/optimizing-compile-dispatcher-unittest.cc',
'../test/unittests/compiler-dispatcher/unoptimized-compile-job-unittest.cc',
'../test/unittests/counters-unittest.cc',
'../test/unittests/detachable-vector-unittest.cc',
'../test/unittests/eh-frame-iterator-unittest.cc',
'../test/unittests/eh-frame-writer-unittest.cc',
'../test/unittests/heap/barrier-unittest.cc',
'../test/unittests/heap/bitmap-unittest.cc',
'../test/unittests/heap/embedder-tracing-unittest.cc',
'../test/unittests/heap/gc-idle-time-handler-unittest.cc',
'../test/unittests/heap/gc-tracer-unittest.cc',
'../test/unittests/heap/item-parallel-job-unittest.cc',
'../test/unittests/heap/marking-unittest.cc',
'../test/unittests/heap/memory-reducer-unittest.cc',
'../test/unittests/heap/object-stats-unittest.cc',
'../test/unittests/heap/heap-unittest.cc',
'../test/unittests/heap/scavenge-job-unittest.cc',
'../test/unittests/heap/slot-set-unittest.cc',
'../test/unittests/heap/spaces-unittest.cc',
'../test/unittests/heap/unmapper-unittest.cc',
'../test/unittests/heap/worklist-unittest.cc',
'../test/unittests/interpreter/bytecodes-unittest.cc',
'../test/unittests/interpreter/bytecode-array-builder-unittest.cc',
'../test/unittests/interpreter/bytecode-array-iterator-unittest.cc',
'../test/unittests/interpreter/bytecode-array-random-iterator-unittest.cc',
'../test/unittests/interpreter/bytecode-array-writer-unittest.cc',
'../test/unittests/interpreter/bytecode-decoder-unittest.cc',
'../test/unittests/interpreter/bytecode-node-unittest.cc',
'../test/unittests/interpreter/bytecode-operands-unittest.cc',
'../test/unittests/interpreter/bytecode-register-allocator-unittest.cc',
'../test/unittests/interpreter/bytecode-register-optimizer-unittest.cc',
'../test/unittests/interpreter/bytecode-source-info-unittest.cc',
'../test/unittests/interpreter/bytecode-utils.h',
'../test/unittests/interpreter/constant-array-builder-unittest.cc',
'../test/unittests/interpreter/interpreter-assembler-unittest.cc',
'../test/unittests/interpreter/interpreter-assembler-unittest.h',
'../test/unittests/libplatform/default-platform-unittest.cc',
'../test/unittests/libplatform/task-queue-unittest.cc',
'../test/unittests/libplatform/worker-thread-unittest.cc',
'../test/unittests/locked-queue-unittest.cc',
'../test/unittests/object-unittest.cc',
'../test/unittests/parser/ast-value-unittest.cc',
'../test/unittests/parser/preparser-unittest.cc',
'../test/unittests/register-configuration-unittest.cc',
'../test/unittests/run-all-unittests.cc',
'../test/unittests/source-position-table-unittest.cc',
'../test/unittests/test-helpers.cc',
'../test/unittests/test-helpers.h',
'../test/unittests/test-utils.h',
'../test/unittests/test-utils.cc',
'../test/unittests/unicode-unittest.cc',
'../test/unittests/utils-unittest.cc',
'../test/unittests/value-serializer-unittest.cc',
'../test/unittests/zone/segmentpool-unittest.cc',
'../test/unittests/zone/zone-allocator-unittest.cc',
'../test/unittests/zone/zone-chunk-list-unittest.cc',
'../test/unittests/zone/zone-unittest.cc',
'../test/unittests/wasm/control-transfer-unittest.cc',
'../test/unittests/wasm/decoder-unittest.cc',
'../test/unittests/wasm/function-body-decoder-unittest.cc',
'../test/unittests/wasm/wasm-code-manager-unittest.cc',
'../test/unittests/wasm/leb-helper-unittest.cc',
'../test/unittests/wasm/loop-assignment-analysis-unittest.cc',
'../test/unittests/wasm/module-decoder-unittest.cc',
'../test/unittests/wasm/streaming-decoder-unittest.cc',
'../test/unittests/wasm/trap-handler-unittest.cc',
'../test/unittests/wasm/wasm-macro-gen-unittest.cc',
'../test/unittests/wasm/wasm-module-builder-unittest.cc',
'../test/unittests/wasm/wasm-opcodes-unittest.cc',
],
'unittests_sources_arm': [
'../test/unittests/compiler/arm/instruction-selector-arm-unittest.cc',
],
'unittests_sources_arm64': [
'../test/unittests/compiler/arm64/instruction-selector-arm64-unittest.cc',
],
'unittests_sources_ia32': [
'../test/unittests/compiler/ia32/instruction-selector-ia32-unittest.cc',
],
'unittests_sources_mips': [
'../test/unittests/compiler/mips/instruction-selector-mips-unittest.cc',
],
'unittests_sources_mips64': [
'../test/unittests/compiler/mips64/instruction-selector-mips64-unittest.cc',
],
'unittests_sources_x64': [
'../test/unittests/compiler/x64/instruction-selector-x64-unittest.cc',
],
'unittests_sources_ppc': [
'../test/unittests/compiler/ppc/instruction-selector-ppc-unittest.cc',
],
'unittests_sources_s390': [
'../test/unittests/compiler/s390/instruction-selector-s390-unittest.cc',
],
},
'includes': ['toolchain.gypi', 'features.gypi'],
'targets': [
{
'target_name': 'unittests',
'type': 'executable',
'variables': {
'optimize': 'max',
},
'dependencies': [
'gmock.gyp:gmock',
'gtest.gyp:gtest',
'v8.gyp:v8',
'v8.gyp:v8_libbase',
'v8.gyp:v8_libplatform',
'v8.gyp:v8_maybe_snapshot',
],
'include_dirs': [
'..',
],
'sources': [
'<@(unittests_sources)',
],
'conditions': [
['v8_target_arch=="arm"', {
'sources': [
'<@(unittests_sources_arm)',
],
}],
['v8_target_arch=="arm64"', {
'sources': [
'<@(unittests_sources_arm64)',
],
}],
['v8_target_arch=="ia32"', {
'sources': [
'<@(unittests_sources_ia32)',
],
}],
['v8_target_arch=="mips"', {
'sources': [
'<@(unittests_sources_mips)',
],
}],
['v8_target_arch=="mipsel"', {
'sources': [
'<@(unittests_sources_mips)',
],
}],
['v8_target_arch=="mips64"', {
'sources': [
'<@(unittests_sources_mips64)',
],
}],
['v8_target_arch=="mips64el"', {
'sources': [
'<@(unittests_sources_mips64)',
],
}],
['v8_target_arch=="x64"', {
'sources': [
'<@(unittests_sources_x64)',
],
}],
['v8_target_arch=="ppc" or v8_target_arch=="ppc64"', {
'sources': [
'<@(unittests_sources_ppc)',
],
}],
['v8_target_arch=="s390" or v8_target_arch=="s390x"', {
'sources': [
'<@(unittests_sources_s390)',
],
}],
['OS=="aix"', {
'ldflags': [ '-Wl,-bbigtoc' ],
}],
['v8_enable_i18n_support==1', {
'dependencies': [
'<(icu_gyp_path):icui18n',
'<(icu_gyp_path):icuuc',
],
}],
['v8_use_snapshot=="true"', {
'dependencies': ['v8.gyp:v8_initializers'],
}],
],
},
],
'conditions': [
['test_isolation_mode != "noop"', {
'targets': [
{
'target_name': 'unittests_run',
'type': 'none',
'dependencies': [
'unittests',
],
'includes': [
'isolate.gypi',
],
'sources': [
'../test/unittests/unittests.isolate',
],
},
],
}],
],
}

View File

@ -28,12 +28,12 @@ GYP_FILES = [
os.path.join(V8_BASE, 'gypfiles', 'v8vtune.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'samples.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'cctest.gyp'),
os.path.join(V8_BASE, 'test', 'fuzzer', 'fuzzer.gyp'),
os.path.join(V8_BASE, 'test', 'unittests', 'unittests.gyp'),
os.path.join(V8_BASE, 'test', 'inspector', 'inspector.gyp'),
os.path.join(V8_BASE, 'test', 'mkgrokdump', 'mkgrokdump.gyp'),
os.path.join(V8_BASE, 'testing', 'gmock.gyp'),
os.path.join(V8_BASE, 'testing', 'gtest.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'fuzzer.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'unittests.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'inspector-test.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'mkgrokdump.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'gmock.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'gtest.gyp'),
os.path.join(V8_BASE, 'gypfiles', 'parser-shell.gyp'),
]

View File

@ -12,13 +12,13 @@
'dependencies': [
'../gypfiles/cctest.gyp:cctest_run',
'debugger/debugger.gyp:debugger_run',
'fuzzer/fuzzer.gyp:fuzzer_run',
'inspector/inspector.gyp:inspector-test_run',
'../gypfiles/fuzzer.gyp:fuzzer_run',
'../gypfiles/inspector-test.gyp:inspector-test_run',
'intl/intl.gyp:intl_run',
'message/message.gyp:message_run',
'mjsunit/mjsunit.gyp:mjsunit_run',
'preparser/preparser.gyp:preparser_run',
'unittests/unittests.gyp:unittests_run',
'../gypfiles/unittests.gyp:unittests_run',
'wasm-spec-tests/wasm-spec-tests.gyp:wasm_spec_tests_run',
'webkit/webkit.gyp:webkit_run',
],

View File

@ -12,13 +12,13 @@
'dependencies': [
'../gypfiles/cctest.gyp:cctest_run',
'debugger/debugger.gyp:debugger_run',
'fuzzer/fuzzer.gyp:fuzzer_run',
'inspector/inspector.gyp:inspector-test_run',
'../gypfiles/fuzzer.gyp:fuzzer_run',
'../gypfiles/inspector-test.gyp:inspector-test_run',
'intl/intl.gyp:intl_run',
'message/message.gyp:message_run',
'mjsunit/mjsunit.gyp:mjsunit_run',
'preparser/preparser.gyp:preparser_run',
'unittests/unittests.gyp:unittests_run',
'../gypfiles/unittests.gyp:unittests_run',
'wasm-spec-tests/wasm-spec-tests.gyp:wasm_spec_tests_run',
],
'includes': [

View File

@ -45,18 +45,10 @@ the fuzzer is called `foo`.
* Use this binary to reproduce issues found by cluster fuzz, e.g.
`out/x64.debug/v8_simple_foo_fuzzer testcase.foo`
5. Copy the build rules of an existing fuzzer in
[test/fuzzer/fuzzer.gyp](https://cs.chromium.org/chromium/src/v8/test/fuzzer/fuzzer.gyp),
e.g. the build rules for the
[wasm.cc](https://cs.chromium.org/chromium/src/v8/test/fuzzer/wasm.cc) fuzzer
are `v8_simple_wasm_fuzzer` and `wasm_fuzzer_lib`
* This build rule is needed to compile with gyp
6. Copy the binary name and the test directory name in
5. Copy the binary name and the test directory name in
[test/fuzzer/fuzzer.isolate](https://cs.chromium.org/chromium/src/v8/test/fuzzer/fuzzer.isolate)
7. Add the fuzzer to the FuzzerTestSuite in
6. Add the fuzzer to the FuzzerTestSuite in
[test/fuzzer/testcfg.py](https://cs.chromium.org/chromium/src/v8/test/fuzzer/testcfg.py)
* This step is needed to run the fuzzer with the files created in Step 2 on

View File

@ -1,306 +0,0 @@
# Copyright 2014 the V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
# The sources are kept automatically in sync with BUILD.gn.
{
'variables': {
'v8_code': 1,
'unittests_sources': [
'allocation-unittest.cc',
'api/access-check-unittest.cc',
'api/exception-unittest.cc',
'api/interceptor-unittest.cc',
'api/isolate-unittest.cc',
'api/remote-object-unittest.cc',
'api/v8-object-unittest.cc',
'asmjs/asm-scanner-unittest.cc',
'asmjs/asm-types-unittest.cc',
'asmjs/switch-logic-unittest.cc',
'base/atomic-utils-unittest.cc',
'base/bits-unittest.cc',
'base/cpu-unittest.cc',
'base/division-by-constant-unittest.cc',
'base/flags-unittest.cc',
'base/functional-unittest.cc',
'base/ieee754-unittest.cc',
'base/logging-unittest.cc',
'base/macros-unittest.cc',
'base/iterator-unittest.cc',
'base/ostreams-unittest.cc',
'base/platform/condition-variable-unittest.cc',
'base/platform/mutex-unittest.cc',
'base/platform/platform-unittest.cc',
'base/platform/semaphore-unittest.cc',
'base/platform/time-unittest.cc',
'base/sys-info-unittest.cc',
'base/template-utils-unittest.cc',
'base/utils/random-number-generator-unittest.cc',
'bigint-unittest.cc',
'cancelable-tasks-unittest.cc',
'char-predicates-unittest.cc',
"code-stub-assembler-unittest.cc",
"code-stub-assembler-unittest.h",
'compiler/branch-elimination-unittest.cc',
'compiler/bytecode-analysis-unittest.cc',
'compiler/checkpoint-elimination-unittest.cc',
"compiler/code-assembler-unittest.cc",
"compiler/code-assembler-unittest.h",
'compiler/common-operator-reducer-unittest.cc',
'compiler/common-operator-unittest.cc',
'compiler/compiler-test-utils.h',
'compiler/control-equivalence-unittest.cc',
'compiler/control-flow-optimizer-unittest.cc',
'compiler/dead-code-elimination-unittest.cc',
'compiler/diamond-unittest.cc',
'compiler/effect-control-linearizer-unittest.cc',
'compiler/graph-reducer-unittest.cc',
'compiler/graph-reducer-unittest.h',
'compiler/graph-trimmer-unittest.cc',
'compiler/graph-unittest.cc',
'compiler/graph-unittest.h',
'compiler/instruction-unittest.cc',
'compiler/instruction-selector-unittest.cc',
'compiler/instruction-selector-unittest.h',
'compiler/instruction-sequence-unittest.cc',
'compiler/instruction-sequence-unittest.h',
'compiler/int64-lowering-unittest.cc',
'compiler/js-builtin-reducer-unittest.cc',
'compiler/js-create-lowering-unittest.cc',
'compiler/js-intrinsic-lowering-unittest.cc',
'compiler/js-operator-unittest.cc',
'compiler/js-typed-lowering-unittest.cc',
'compiler/linkage-tail-call-unittest.cc',
'compiler/live-range-builder.h',
'compiler/regalloc/live-range-unittest.cc',
'compiler/load-elimination-unittest.cc',
'compiler/loop-peeling-unittest.cc',
'compiler/machine-operator-reducer-unittest.cc',
'compiler/machine-operator-unittest.cc',
'compiler/regalloc/move-optimizer-unittest.cc',
'compiler/node-cache-unittest.cc',
'compiler/node-matchers-unittest.cc',
'compiler/node-properties-unittest.cc',
'compiler/node-test-utils.cc',
'compiler/node-test-utils.h',
'compiler/node-unittest.cc',
'compiler/opcodes-unittest.cc',
'compiler/persistent-unittest.cc',
'compiler/regalloc/register-allocator-unittest.cc',
'compiler/schedule-unittest.cc',
'compiler/scheduler-unittest.cc',
'compiler/scheduler-rpo-unittest.cc',
'compiler/simplified-lowering-unittest.cc',
'compiler/simplified-operator-reducer-unittest.cc',
'compiler/simplified-operator-unittest.cc',
'compiler/state-values-utils-unittest.cc',
'compiler/typed-optimization-unittest.cc',
'compiler/typer-unittest.cc',
'compiler/value-numbering-reducer-unittest.cc',
'compiler/zone-stats-unittest.cc',
'compiler-dispatcher/compiler-dispatcher-tracer-unittest.cc',
'compiler-dispatcher/compiler-dispatcher-unittest.cc',
'compiler-dispatcher/optimizing-compile-dispatcher-unittest.cc',
'compiler-dispatcher/unoptimized-compile-job-unittest.cc',
'counters-unittest.cc',
'detachable-vector-unittest.cc',
'eh-frame-iterator-unittest.cc',
'eh-frame-writer-unittest.cc',
'heap/barrier-unittest.cc',
'heap/bitmap-unittest.cc',
'heap/embedder-tracing-unittest.cc',
'heap/gc-idle-time-handler-unittest.cc',
'heap/gc-tracer-unittest.cc',
'heap/item-parallel-job-unittest.cc',
'heap/marking-unittest.cc',
'heap/memory-reducer-unittest.cc',
'heap/object-stats-unittest.cc',
'heap/heap-unittest.cc',
'heap/scavenge-job-unittest.cc',
'heap/slot-set-unittest.cc',
'heap/spaces-unittest.cc',
'heap/unmapper-unittest.cc',
'heap/worklist-unittest.cc',
'interpreter/bytecodes-unittest.cc',
'interpreter/bytecode-array-builder-unittest.cc',
'interpreter/bytecode-array-iterator-unittest.cc',
'interpreter/bytecode-array-random-iterator-unittest.cc',
'interpreter/bytecode-array-writer-unittest.cc',
'interpreter/bytecode-decoder-unittest.cc',
'interpreter/bytecode-node-unittest.cc',
'interpreter/bytecode-operands-unittest.cc',
'interpreter/bytecode-register-allocator-unittest.cc',
'interpreter/bytecode-register-optimizer-unittest.cc',
'interpreter/bytecode-source-info-unittest.cc',
'interpreter/bytecode-utils.h',
'interpreter/constant-array-builder-unittest.cc',
'interpreter/interpreter-assembler-unittest.cc',
'interpreter/interpreter-assembler-unittest.h',
'libplatform/default-platform-unittest.cc',
'libplatform/task-queue-unittest.cc',
'libplatform/worker-thread-unittest.cc',
'locked-queue-unittest.cc',
'object-unittest.cc',
'parser/ast-value-unittest.cc',
'parser/preparser-unittest.cc',
'register-configuration-unittest.cc',
'run-all-unittests.cc',
'source-position-table-unittest.cc',
'test-helpers.cc',
'test-helpers.h',
'test-utils.h',
'test-utils.cc',
'unicode-unittest.cc',
'utils-unittest.cc',
'value-serializer-unittest.cc',
'zone/segmentpool-unittest.cc',
'zone/zone-allocator-unittest.cc',
'zone/zone-chunk-list-unittest.cc',
'zone/zone-unittest.cc',
'wasm/control-transfer-unittest.cc',
'wasm/decoder-unittest.cc',
'wasm/function-body-decoder-unittest.cc',
'wasm/wasm-code-manager-unittest.cc',
'wasm/leb-helper-unittest.cc',
'wasm/loop-assignment-analysis-unittest.cc',
'wasm/module-decoder-unittest.cc',
'wasm/streaming-decoder-unittest.cc',
'wasm/trap-handler-unittest.cc',
'wasm/wasm-macro-gen-unittest.cc',
'wasm/wasm-module-builder-unittest.cc',
'wasm/wasm-opcodes-unittest.cc',
],
'unittests_sources_arm': [
'compiler/arm/instruction-selector-arm-unittest.cc',
],
'unittests_sources_arm64': [
'compiler/arm64/instruction-selector-arm64-unittest.cc',
],
'unittests_sources_ia32': [
'compiler/ia32/instruction-selector-ia32-unittest.cc',
],
'unittests_sources_mips': [
'compiler/mips/instruction-selector-mips-unittest.cc',
],
'unittests_sources_mips64': [
'compiler/mips64/instruction-selector-mips64-unittest.cc',
],
'unittests_sources_x64': [
'compiler/x64/instruction-selector-x64-unittest.cc',
],
'unittests_sources_ppc': [
'compiler/ppc/instruction-selector-ppc-unittest.cc',
],
'unittests_sources_s390': [
'compiler/s390/instruction-selector-s390-unittest.cc',
],
},
'includes': ['../../gypfiles/toolchain.gypi', '../../gypfiles/features.gypi'],
'targets': [
{
'target_name': 'unittests',
'type': 'executable',
'variables': {
'optimize': 'max',
},
'dependencies': [
'../../testing/gmock.gyp:gmock',
'../../testing/gtest.gyp:gtest',
'../../gypfiles/v8.gyp:v8',
'../../gypfiles/v8.gyp:v8_libbase',
'../../gypfiles/v8.gyp:v8_libplatform',
'../../gypfiles/v8.gyp:v8_maybe_snapshot',
],
'include_dirs': [
'../..',
],
'sources': [
'<@(unittests_sources)',
],
'conditions': [
['v8_target_arch=="arm"', {
'sources': [
'<@(unittests_sources_arm)',
],
}],
['v8_target_arch=="arm64"', {
'sources': [
'<@(unittests_sources_arm64)',
],
}],
['v8_target_arch=="ia32"', {
'sources': [
'<@(unittests_sources_ia32)',
],
}],
['v8_target_arch=="mips"', {
'sources': [
'<@(unittests_sources_mips)',
],
}],
['v8_target_arch=="mipsel"', {
'sources': [
'<@(unittests_sources_mips)',
],
}],
['v8_target_arch=="mips64"', {
'sources': [
'<@(unittests_sources_mips64)',
],
}],
['v8_target_arch=="mips64el"', {
'sources': [
'<@(unittests_sources_mips64)',
],
}],
['v8_target_arch=="x64"', {
'sources': [
'<@(unittests_sources_x64)',
],
}],
['v8_target_arch=="ppc" or v8_target_arch=="ppc64"', {
'sources': [
'<@(unittests_sources_ppc)',
],
}],
['v8_target_arch=="s390" or v8_target_arch=="s390x"', {
'sources': [
'<@(unittests_sources_s390)',
],
}],
['OS=="aix"', {
'ldflags': [ '-Wl,-bbigtoc' ],
}],
['v8_enable_i18n_support==1', {
'dependencies': [
'<(icu_gyp_path):icui18n',
'<(icu_gyp_path):icuuc',
],
}],
['v8_use_snapshot=="true"', {
'dependencies': ['../../gypfiles/v8.gyp:v8_initializers'],
}],
],
},
],
'conditions': [
['test_isolation_mode != "noop"', {
'targets': [
{
'target_name': 'unittests_run',
'type': 'none',
'dependencies': [
'unittests',
],
'includes': [
'../../gypfiles/isolate.gypi',
],
'sources': [
'unittests.isolate',
],
},
],
}],
],
}

View File

@ -1,72 +0,0 @@
# Copyright 2014 the V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
{
'targets': [
{
'target_name': 'gmock',
'type': 'static_library',
'dependencies': [
'gtest.gyp:gtest',
],
'sources': [
# Sources based on files in r173 of gmock.
'gmock/include/gmock/gmock-actions.h',
'gmock/include/gmock/gmock-cardinalities.h',
'gmock/include/gmock/gmock-generated-actions.h',
'gmock/include/gmock/gmock-generated-function-mockers.h',
'gmock/include/gmock/gmock-generated-matchers.h',
'gmock/include/gmock/gmock-generated-nice-strict.h',
'gmock/include/gmock/gmock-matchers.h',
'gmock/include/gmock/gmock-spec-builders.h',
'gmock/include/gmock/gmock.h',
'gmock/include/gmock/internal/gmock-generated-internal-utils.h',
'gmock/include/gmock/internal/gmock-internal-utils.h',
'gmock/include/gmock/internal/gmock-port.h',
'gmock/src/gmock-all.cc',
'gmock/src/gmock-cardinalities.cc',
'gmock/src/gmock-internal-utils.cc',
'gmock/src/gmock-matchers.cc',
'gmock/src/gmock-spec-builders.cc',
'gmock/src/gmock.cc',
'gmock-support.h', # gMock helpers
'gmock_custom/gmock/internal/custom/gmock-port.h',
],
'sources!': [
'gmock/src/gmock-all.cc', # Not needed by our build.
],
'include_dirs': [
'gmock_custom',
'gmock',
'gmock/include',
],
'all_dependent_settings': {
'include_dirs': [
'gmock_custom',
'gmock/include', # So that gmock headers can find themselves.
],
},
'export_dependent_settings': [
'gtest.gyp:gtest',
],
'conditions': [
['want_separate_host_toolset==1', {
'toolsets': ['host', 'target'],
}, {
'toolsets': ['target'],
}],
],
},
{
'target_name': 'gmock_main',
'type': 'static_library',
'dependencies': [
'gmock',
],
'sources': [
'gmock/src/gmock_main.cc',
],
},
],
}