Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: testing/gtest.gyp

Issue 165330: Disable RTTI and C++ exceptions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/profile.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 { 5 {
6 'includes': [ 6 'includes': [
7 '../build/common.gypi', 7 '../build/common.gypi',
8 ], 8 ],
9 'targets': [ 9 'targets': [
10 { 10 {
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 'platform_test.h', 45 'platform_test.h',
46 ], 46 ],
47 'sources!': [ 47 'sources!': [
48 'gtest/src/gtest-all.cc', # Not needed by our build. 48 'gtest/src/gtest-all.cc', # Not needed by our build.
49 ], 49 ],
50 'include_dirs': [ 50 'include_dirs': [
51 'gtest', 51 'gtest',
52 'gtest/include', 52 'gtest/include',
53 ], 53 ],
54 'conditions': [ 54 'conditions': [
55 [ 'OS == "mac"', { 'sources': [ 'platform_test_mac.mm' ] } ], 55 ['OS == "mac"', {
56 'sources': [
57 'platform_test_mac.mm'
58 ],
59 }],
60 ['OS == "mac" or OS == "linux"', {
61 'defines': [
62 # gtest isn't able to figure out when RTTI is disabled for gcc
63 # versions older than 4.3.2, and assumes it's enabled. Our Mac
64 # and Linux builds disable RTTI, and cannot guarantee that the
65 # compiler will be 4.3.2. or newer. The Mac, for example, uses
66 # 4.2.1 as that is the latest available on that platform. gtest
67 # must be instructed that RTTI is disabled here, and for any
68 # direct dependents that might include gtest headers.
69 'GTEST_HAS_RTTI=0',
70 ],
71 'direct_dependent_settings': {
72 'defines': [
73 'GTEST_HAS_RTTI=0',
74 ],
75 },
76 }],
56 ], 77 ],
57 'direct_dependent_settings': { 78 'direct_dependent_settings': {
58 'defines': [ 79 'defines': [
59 'UNIT_TEST', 80 'UNIT_TEST',
60 ], 81 ],
61 'include_dirs': [ 82 'include_dirs': [
62 'gtest/include', # So that gtest headers can find themselves. 83 'gtest/include', # So that gtest headers can find themselves.
63 ], 84 ],
64 'target_conditions': [ 85 'target_conditions': [
65 ['_type=="executable"', {'test': 1}], 86 ['_type=="executable"', {'test': 1}],
66 ], 87 ],
67 }, 88 },
68 }, 89 },
69 { 90 {
70 # Note that calling this "gtest_main" confuses the scons build, 91 # Note that calling this "gtest_main" confuses the scons build,
71 # which uses "_main" on scons files to produce special behavior. 92 # which uses "_main" on scons files to produce special behavior.
72 'target_name': 'gtestmain', 93 'target_name': 'gtestmain',
73 'type': '<(library)', 94 'type': '<(library)',
74 'dependencies': [ 95 'dependencies': [
75 'gtest', 96 'gtest',
76 ], 97 ],
77 'sources': [ 98 'sources': [
78 'gtest/src/gtest_main.cc', 99 'gtest/src/gtest_main.cc',
79 ], 100 ],
80 }, 101 },
81 ], 102 ],
82 } 103 }
OLDNEW
« no previous file with comments | « chrome/browser/profile.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698