Allow Crashpad to build in the Chromium tree.

When building in the Chromium tree, this swaps out Crashpad’s copies of
mini_chromium, gtest, and gmock for the equivalents provided by
Chromium. A GYP variable, crashpad_in_chromium, is used to determine the
behavior.

gclient doesn’t sync sub-DEPS, so when doing an in-Chromium build,
Crashpad’s copies of mini_chromium, gtest, and gmock are not available.

BUG=crashpad:12
R=rsesek@chromium.org

Review URL: https://codereview.chromium.org/986033002
This commit is contained in:
Mark Mentovai 2015-03-09 15:25:42 -04:00
parent 32a9d410ca
commit b665a0db07
11 changed files with 539 additions and 390 deletions

View File

@ -0,0 +1,43 @@
# Copyright 2015 The Crashpad Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
{
# Crashpad can build as a standalone project or as part of Chromium. When
# building as a standalone project, it uses mini_chromium to provide the base
# library, and uses its own copy of gtest in third_party. When building as
# part of Chromium, it uses Chromiums base library and copy of gtest. In
# order for Crashpads .gyp files to reference the correct versions depending
# on whether building standalone or as a part of Chromium, include this .gypi
# file and reference the crashpad_in_chromium variable.
'variables': {
'variables': {
# When building as a standalone project, build/gyp_crashpad.py sets
# crashpad_standalone to 1, and this % assignment will not override it.
# The variable will not be set when building as part of Chromium, so in
# that case, this will define it with value 0.
'crashpad_standalone%': 0,
},
'conditions': [
['crashpad_standalone!=0', {
'crashpad_in_chromium': 0,
}, {
'crashpad_in_chromium': 1,
}],
],
'crashpad_in_chromium': '<(crashpad_in_chromium)',
},
}

View File

@ -30,6 +30,7 @@ def main(args):
crashpad_dir_or_dot = crashpad_dir if crashpad_dir is not '' else '.'
args.extend(['-D', 'crashpad_standalone=1'])
args.extend(['--include', os.path.join(crashpad_dir,
'third_party',
'mini_chromium',

View File

@ -22,7 +22,7 @@
'type': 'static_library',
'dependencies': [
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -63,7 +63,7 @@
'../compat/compat.gyp:crashpad_compat',
'../third_party/gtest/gtest.gyp:gtest',
'../third_party/gtest/gtest.gyp:gtest_main',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
'../util/util.gyp:crashpad_util_test_lib',
],

View File

@ -27,7 +27,7 @@
'../compat/compat.gyp:crashpad_compat',
'../minidump/minidump.gyp:crashpad_minidump',
'../snapshot/snapshot.gyp:crashpad_snapshot',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../tools/tools.gyp:crashpad_tool_support',
'../util/util.gyp:crashpad_util',
],

View File

@ -23,7 +23,7 @@
'dependencies': [
'../compat/compat.gyp:crashpad_compat',
'../snapshot/snapshot.gyp:crashpad_snapshot',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'export_dependent_settings': [
@ -80,7 +80,7 @@
'../snapshot/snapshot.gyp:crashpad_snapshot_test_lib',
'../third_party/gtest/gtest.gyp:gtest',
'../third_party/gtest/gtest.gyp:gtest_main',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
],
'include_dirs': [
'..',

View File

@ -23,7 +23,7 @@
'dependencies': [
'../client/client.gyp:crashpad_client',
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -107,7 +107,7 @@
'dependencies': [
'crashpad_snapshot',
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -139,7 +139,7 @@
'../compat/compat.gyp:crashpad_compat',
'../third_party/gtest/gtest.gyp:gtest',
'../third_party/gtest/gtest.gyp:gtest_main',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
'../util/util.gyp:crashpad_util_test_lib',
],

View File

@ -13,178 +13,208 @@
# limitations under the License.
{
'targets': [
{
'target_name': 'gmock',
'type': 'static_library',
'dependencies': [
'../gtest/gtest.gyp:gtest',
],
'include_dirs': [
'gmock',
'gmock/include',
],
'sources': [
'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-more-actions.h',
'gmock/include/gmock/gmock-more-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',
],
'sources!': [
'gmock/src/gmock-all.cc',
],
'includes': [
'../../build/crashpad_in_chromium.gypi',
],
'conditions': [
['crashpad_in_chromium==0', {
'targets': [
{
'target_name': 'gmock',
'type': 'static_library',
'dependencies': [
'../gtest/gtest.gyp:gtest',
],
'include_dirs': [
'gmock',
'gmock/include',
],
'sources': [
'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-more-actions.h',
'gmock/include/gmock/gmock-more-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',
],
'sources!': [
'gmock/src/gmock-all.cc',
],
# gmock relies heavily on objects with static storage duration.
'xcode_settings': {
'WARNING_CFLAGS!': [
'-Wexit-time-destructors',
],
},
'cflags!': [
'-Wexit-time-destructors',
],
# gmock relies heavily on objects with static storage duration.
'xcode_settings': {
'WARNING_CFLAGS!': [
'-Wexit-time-destructors',
],
},
'cflags!': [
'-Wexit-time-destructors',
],
'direct_dependent_settings': {
'include_dirs': [
'gmock/include',
],
'conditions': [
['clang!=0', {
# The MOCK_METHODn() macros do not specify “override”, which
# triggers this warning in users: “error: 'Method' overrides a
# member function but is not marked 'override'
# [-Werror,-Winconsistent-missing-override]”. Suppress these
# warnings, and add -Wno-unknown-warning-option because only recent
# versions of clang (trunk r220703 and later, version 3.6 and
# later) recognize it.
'direct_dependent_settings': {
'include_dirs': [
'gmock/include',
],
'conditions': [
['OS=="mac"', {
'xcode_settings': {
'WARNING_CFLAGS': [
'-Wno-inconsistent-missing-override',
'-Wno-unknown-warning-option',
],
},
}],
['OS=="linux"', {
'cflags': [
'-Wno-inconsistent-missing-override',
'-Wno-unknown-warning-option',
['clang!=0', {
# The MOCK_METHODn() macros do not specify “override”, which
# triggers this warning in users: “error: 'Method' overrides a
# member function but is not marked 'override'
# [-Werror,-Winconsistent-missing-override]”. Suppress these
# warnings, and add -Wno-unknown-warning-option because only
# recent versions of clang (trunk r220703 and later, version
# 3.6 and later) recognize it.
'conditions': [
['OS=="mac"', {
'xcode_settings': {
'WARNING_CFLAGS': [
'-Wno-inconsistent-missing-override',
'-Wno-unknown-warning-option',
],
},
}],
['OS=="linux"', {
'cflags': [
'-Wno-inconsistent-missing-override',
'-Wno-unknown-warning-option',
],
}],
],
}],
],
}],
],
},
'export_dependent_settings': [
'../gtest/gtest.gyp:gtest',
},
'export_dependent_settings': [
'../gtest/gtest.gyp:gtest',
],
},
{
'target_name': 'gmock_main',
'type': 'static_library',
'dependencies': [
'gmock',
'../gtest/gtest.gyp:gtest',
],
'sources': [
'gmock/src/gmock_main.cc',
],
},
{
'target_name': 'gmock_test_executable',
'type': 'none',
'dependencies': [
'gmock',
'../gtest/gtest.gyp:gtest',
],
'direct_dependent_settings': {
'type': 'executable',
'include_dirs': [
'gmock',
],
},
'export_dependent_settings': [
'gmock',
'../gtest/gtest.gyp:gtest',
],
},
{
'target_name': 'gmock_all_test',
'dependencies': [
'gmock_test_executable',
'gmock_main',
],
'sources': [
'gmock/test/gmock-actions_test.cc',
'gmock/test/gmock-cardinalities_test.cc',
'gmock/test/gmock-generated-actions_test.cc',
'gmock/test/gmock-generated-function-mockers_test.cc',
'gmock/test/gmock-generated-internal-utils_test.cc',
'gmock/test/gmock-generated-matchers_test.cc',
'gmock/test/gmock-internal-utils_test.cc',
'gmock/test/gmock-matchers_test.cc',
'gmock/test/gmock-more-actions_test.cc',
'gmock/test/gmock-nice-strict_test.cc',
'gmock/test/gmock-port_test.cc',
'gmock/test/gmock_test.cc',
],
},
{
'target_name': 'gmock_link_test',
'dependencies': [
'gmock_test_executable',
'gmock_main',
],
'sources': [
'gmock/test/gmock_link_test.cc',
'gmock/test/gmock_link_test.h',
'gmock/test/gmock_link2_test.cc',
],
},
{
'target_name': 'gmock_spec_builders_test',
'dependencies': [
'gmock_test_executable',
],
'sources': [
'gmock/test/gmock-spec-builders_test.cc',
],
},
{
'target_name': 'gmock_stress_test',
'dependencies': [
'gmock_test_executable',
],
'sources': [
'gmock/test/gmock_stress_test.cc',
],
},
{
'target_name': 'gmock_all_tests',
'type': 'none',
'dependencies': [
'gmock_all_test',
'gmock_link_test',
'gmock_spec_builders_test',
'gmock_stress_test',
],
},
],
},
{
'target_name': 'gmock_main',
'type': 'static_library',
'dependencies': [
'gmock',
'../gtest/gtest.gyp:gtest',
}, { # else: crashpad_in_chromium!=0
'targets': [
{
'target_name': 'gmock',
'type': 'none',
'dependencies': [
'../../../../../testing/gmock.gyp:gmock',
],
'export_dependent_settings': [
'../../../../../testing/gmock.gyp:gmock',
],
},
{
'target_name': 'gmock_main',
'type': 'none',
'dependencies': [
'../../../../../testing/gmock.gyp:gmock_main',
],
'export_dependent_settings': [
'../../../../../testing/gmock.gyp:gmock_main',
],
},
],
'sources': [
'gmock/src/gmock_main.cc',
],
},
{
'target_name': 'gmock_test_executable',
'type': 'none',
'dependencies': [
'gmock',
'../gtest/gtest.gyp:gtest',
],
'direct_dependent_settings': {
'type': 'executable',
'include_dirs': [
'gmock',
],
},
'export_dependent_settings': [
'gmock',
'../gtest/gtest.gyp:gtest',
],
},
{
'target_name': 'gmock_all_test',
'dependencies': [
'gmock_test_executable',
'gmock_main',
],
'sources': [
'gmock/test/gmock-actions_test.cc',
'gmock/test/gmock-cardinalities_test.cc',
'gmock/test/gmock-generated-actions_test.cc',
'gmock/test/gmock-generated-function-mockers_test.cc',
'gmock/test/gmock-generated-internal-utils_test.cc',
'gmock/test/gmock-generated-matchers_test.cc',
'gmock/test/gmock-internal-utils_test.cc',
'gmock/test/gmock-matchers_test.cc',
'gmock/test/gmock-more-actions_test.cc',
'gmock/test/gmock-nice-strict_test.cc',
'gmock/test/gmock-port_test.cc',
'gmock/test/gmock_test.cc',
],
},
{
'target_name': 'gmock_link_test',
'dependencies': [
'gmock_test_executable',
'gmock_main',
],
'sources': [
'gmock/test/gmock_link_test.cc',
'gmock/test/gmock_link_test.h',
'gmock/test/gmock_link2_test.cc',
],
},
{
'target_name': 'gmock_spec_builders_test',
'dependencies': [
'gmock_test_executable',
],
'sources': [
'gmock/test/gmock-spec-builders_test.cc',
],
},
{
'target_name': 'gmock_stress_test',
'dependencies': [
'gmock_test_executable',
],
'sources': [
'gmock/test/gmock_stress_test.cc',
],
},
{
'target_name': 'gmock_all_tests',
'type': 'none',
'dependencies': [
'gmock_all_test',
'gmock_link_test',
'gmock_spec_builders_test',
'gmock_stress_test',
],
},
}],
],
}

View File

@ -13,213 +13,243 @@
# limitations under the License.
{
'targets': [
{
'target_name': 'gtest',
'type': 'static_library',
'include_dirs': [
'gtest',
'gtest/include',
],
'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/gtest_prod.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.cc',
'gtest/src/gtest-death-test.cc',
'gtest/src/gtest-filepath.cc',
'gtest/src/gtest-port.cc',
'gtest/src/gtest-printers.cc',
'gtest/src/gtest-test-part.cc',
'gtest/src/gtest-typed-test.cc',
],
'sources!': [
'gtest/src/gtest-all.cc',
],
'includes': [
'../../build/crashpad_in_chromium.gypi',
],
'conditions': [
['crashpad_in_chromium==0', {
'targets': [
{
'target_name': 'gtest',
'type': 'static_library',
'include_dirs': [
'gtest',
'gtest/include',
],
'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/gtest_prod.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.cc',
'gtest/src/gtest-death-test.cc',
'gtest/src/gtest-filepath.cc',
'gtest/src/gtest-port.cc',
'gtest/src/gtest-printers.cc',
'gtest/src/gtest-test-part.cc',
'gtest/src/gtest-typed-test.cc',
],
'sources!': [
'gtest/src/gtest-all.cc',
],
# gtest relies heavily on objects with static storage duration.
'xcode_settings': {
'WARNING_CFLAGS!': [
'-Wexit-time-destructors',
],
},
'cflags!': [
'-Wexit-time-destructors',
],
# gtest relies heavily on objects with static storage duration.
'xcode_settings': {
'WARNING_CFLAGS!': [
'-Wexit-time-destructors',
],
},
'cflags!': [
'-Wexit-time-destructors',
],
'direct_dependent_settings': {
'include_dirs': [
'gtest/include',
],
},
},
{
'target_name': 'gtest_main',
'type': 'static_library',
'dependencies': [
'gtest',
'direct_dependent_settings': {
'include_dirs': [
'gtest/include',
],
},
},
{
'target_name': 'gtest_main',
'type': 'static_library',
'dependencies': [
'gtest',
],
'sources': [
'gtest/src/gtest_main.cc',
],
},
{
'target_name': 'gtest_test_executable',
'type': 'none',
'dependencies': [
'gtest',
],
'direct_dependent_settings': {
'type': 'executable',
'include_dirs': [
'gtest',
],
},
'export_dependent_settings': [
'gtest',
],
},
{
'target_name': 'gtest_all_test',
'dependencies': [
'gtest_test_executable',
'gtest_main',
],
'sources': [
'gtest/test/gtest-death-test_test.cc',
'gtest/test/gtest-filepath_test.cc',
'gtest/test/gtest-linked_ptr_test.cc',
'gtest/test/gtest-message_test.cc',
'gtest/test/gtest-options_test.cc',
'gtest/test/gtest-port_test.cc',
'gtest/test/gtest-printers_test.cc',
'gtest/test/gtest-test-part_test.cc',
'gtest/test/gtest-typed-test_test.cc',
'gtest/test/gtest-typed-test_test.h',
'gtest/test/gtest-typed-test2_test.cc',
'gtest/test/gtest_main_unittest.cc',
'gtest/test/gtest_pred_impl_unittest.cc',
'gtest/test/gtest_prod_test.cc',
'gtest/test/gtest_unittest.cc',
'gtest/test/production.cc',
'gtest/test/production.h',
],
},
{
'target_name': 'gtest_environment_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_environment_test.cc',
],
},
{
'target_name': 'gtest_listener_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest-listener_test.cc',
],
},
{
'target_name': 'gtest_no_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_no_test_unittest.cc',
],
},
{
'target_name': 'gtest_param_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest-param-test_test.cc',
'gtest/test/gtest-param-test_test.h',
'gtest/test/gtest-param-test2_test.cc',
],
},
{
'target_name': 'gtest_premature_exit_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_premature_exit_test.cc',
],
},
{
'target_name': 'gtest_repeat_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_repeat_test.cc',
],
},
{
'target_name': 'gtest_sole_header_test',
'dependencies': [
'gtest_test_executable',
'gtest_main',
],
'sources': [
'gtest/test/gtest_sole_header_test.cc',
],
},
{
'target_name': 'gtest_stress_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_stress_test.cc',
],
},
{
'target_name': 'gtest_unittest_api_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest-unittest-api_test.cc',
],
},
{
'target_name': 'gtest_all_tests',
'type': 'none',
'dependencies': [
'gtest_all_test',
'gtest_environment_test',
'gtest_no_test',
'gtest_param_test',
'gtest_premature_exit_test',
'gtest_repeat_test',
'gtest_sole_header_test',
'gtest_stress_test',
'gtest_unittest_api_test',
],
},
],
'sources': [
'gtest/src/gtest_main.cc',
}, { # else: crashpad_in_chromium!=0
'targets': [
{
'target_name': 'gtest',
'type': 'none',
'dependencies': [
'../../../../../testing/gtest.gyp:gtest',
],
'export_dependent_settings': [
'../../../../../testing/gtest.gyp:gtest',
],
},
{
'target_name': 'gtest_main',
'type': 'none',
'dependencies': [
'../../../../../testing/gtest.gyp:gtest_main',
],
'export_dependent_settings': [
'../../../../../testing/gtest.gyp:gtest_main',
],
},
],
},
{
'target_name': 'gtest_test_executable',
'type': 'none',
'dependencies': [
'gtest',
],
'direct_dependent_settings': {
'type': 'executable',
'include_dirs': [
'gtest',
],
},
'export_dependent_settings': [
'gtest',
],
},
{
'target_name': 'gtest_all_test',
'dependencies': [
'gtest_test_executable',
'gtest_main',
],
'sources': [
'gtest/test/gtest-death-test_test.cc',
'gtest/test/gtest-filepath_test.cc',
'gtest/test/gtest-linked_ptr_test.cc',
'gtest/test/gtest-message_test.cc',
'gtest/test/gtest-options_test.cc',
'gtest/test/gtest-port_test.cc',
'gtest/test/gtest-printers_test.cc',
'gtest/test/gtest-test-part_test.cc',
'gtest/test/gtest-typed-test_test.cc',
'gtest/test/gtest-typed-test_test.h',
'gtest/test/gtest-typed-test2_test.cc',
'gtest/test/gtest_main_unittest.cc',
'gtest/test/gtest_pred_impl_unittest.cc',
'gtest/test/gtest_prod_test.cc',
'gtest/test/gtest_unittest.cc',
'gtest/test/production.cc',
'gtest/test/production.h',
],
},
{
'target_name': 'gtest_environment_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_environment_test.cc',
],
},
{
'target_name': 'gtest_listener_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest-listener_test.cc',
],
},
{
'target_name': 'gtest_no_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_no_test_unittest.cc',
],
},
{
'target_name': 'gtest_param_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest-param-test_test.cc',
'gtest/test/gtest-param-test_test.h',
'gtest/test/gtest-param-test2_test.cc',
],
},
{
'target_name': 'gtest_premature_exit_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_premature_exit_test.cc',
],
},
{
'target_name': 'gtest_repeat_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_repeat_test.cc',
],
},
{
'target_name': 'gtest_sole_header_test',
'dependencies': [
'gtest_test_executable',
'gtest_main',
],
'sources': [
'gtest/test/gtest_sole_header_test.cc',
],
},
{
'target_name': 'gtest_stress_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest_stress_test.cc',
],
},
{
'target_name': 'gtest_unittest_api_test',
'dependencies': [
'gtest_test_executable',
],
'sources': [
'gtest/test/gtest-unittest-api_test.cc',
],
},
{
'target_name': 'gtest_all_tests',
'type': 'none',
'dependencies': [
'gtest_all_test',
'gtest_environment_test',
'gtest_no_test',
'gtest_param_test',
'gtest_premature_exit_test',
'gtest_repeat_test',
'gtest_sole_header_test',
'gtest_stress_test',
'gtest_unittest_api_test',
],
},
}],
],
}

View File

@ -0,0 +1,46 @@
# Copyright 2015 The Crashpad Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
{
'includes': [
'../../build/crashpad_in_chromium.gypi',
],
'targets': [
{
# To support both Crashpads standalone build and its in-Chromium build,
# Crashpad code depending on base should do so through this shim, which
# will either get base from mini_chromium or Chromium depending on the
# build type.
'target_name': 'base',
'type': 'none',
'conditions': [
['crashpad_in_chromium==0', {
'dependencies': [
'mini_chromium/base/base.gyp:base',
],
'export_dependent_settings': [
'mini_chromium/base/base.gyp:base',
],
}, { # else: crashpad_in_chromium!=0
'dependencies': [
'../../../../../base/base.gyp:base',
],
'export_dependent_settings': [
'../../../../../base/base.gyp:base',
],
}],
],
},
],
}

View File

@ -37,8 +37,7 @@
# .xcodeproj, which is the directory of the .gyp file.
'conditions': [
['GENERATOR=="ninja"', {
'sectaskaccess_info_plist':
'../../tools/mac/sectaskaccess_info.plist',
'sectaskaccess_info_plist': '<!(pwd)/mac/sectaskaccess_info.plist',
}, { # else: GENERATOR!="ninja"
'sectaskaccess_info_plist': 'mac/sectaskaccess_info.plist',
}],
@ -50,7 +49,7 @@
'target_name': 'crashpad_tool_support',
'type': 'static_library',
'dependencies': [
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
],
'include_dirs': [
'..',
@ -66,7 +65,7 @@
'dependencies': [
'crashpad_tool_support',
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -82,7 +81,7 @@
'dependencies': [
'crashpad_tool_support',
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -108,7 +107,7 @@
'../compat/compat.gyp:crashpad_compat',
'../minidump/minidump.gyp:crashpad_minidump',
'../snapshot/snapshot.gyp:crashpad_snapshot',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -132,7 +131,7 @@
'dependencies': [
'crashpad_tool_support',
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
'../util/util.gyp:crashpad_util',
],
'include_dirs': [
@ -155,7 +154,7 @@
'crashpad_tool_support',
'../client/client.gyp:crashpad_client',
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
],
'include_dirs': [
'..',

View File

@ -22,7 +22,7 @@
'type': 'static_library',
'dependencies': [
'../compat/compat.gyp:crashpad_compat',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
],
'include_dirs': [
'..',
@ -213,10 +213,10 @@
'target_name': 'crashpad_util_test_lib',
'type': 'static_library',
'dependencies': [
'crashpad_util',
'../compat/compat.gyp:crashpad_compat',
'../third_party/gtest/gtest.gyp:gtest',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'crashpad_util',
'../third_party/mini_chromium/mini_chromium.gyp:base',
],
'include_dirs': [
'..',
@ -262,9 +262,9 @@
'crashpad_util_test_multiprocess_exec_test_child',
'../compat/compat.gyp:crashpad_compat',
'../third_party/gmock/gmock.gyp:gmock',
'../third_party/gmock/gmock.gyp:gmock_main',
'../third_party/gtest/gtest.gyp:gtest',
'../third_party/gtest/gtest.gyp:gtest_main',
'../third_party/mini_chromium/mini_chromium/base/base.gyp:base',
'../third_party/mini_chromium/mini_chromium.gyp:base',
],
'include_dirs': [
'..',