blob: 4d1c467ea0666d03eb098f1782508f100089a283 [file] [log] [blame]
Ben Murdoch3ef787d2012-04-12 10:51:47 +01001# Copyright 2012 the V8 project authors. All rights reserved.
Ben Murdochb0fe1622011-05-05 13:52:32 +01002# Redistribution and use in source and binary forms, with or without
3# modification, are permitted provided that the following conditions are
4# met:
5#
6# * Redistributions of source code must retain the above copyright
7# notice, this list of conditions and the following disclaimer.
8# * Redistributions in binary form must reproduce the above
9# copyright notice, this list of conditions and the following
10# disclaimer in the documentation and/or other materials provided
11# with the distribution.
12# * Neither the name of Google Inc. nor the names of its
13# contributors may be used to endorse or promote products derived
14# from this software without specific prior written permission.
15#
16# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
18# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
19# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
20# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
21# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
28{
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000029 'variables': {
Ben Murdochb8a8cc12014-11-26 15:28:44 +000030 'v8_code': 1,
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000031 'generated_file': '<(SHARED_INTERMEDIATE_DIR)/resources.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +010032 },
Ben Murdochb8a8cc12014-11-26 15:28:44 +000033 'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
Ben Murdochb0fe1622011-05-05 13:52:32 +010034 'targets': [
35 {
36 'target_name': 'cctest',
37 'type': 'executable',
38 'dependencies': [
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000039 'resources',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000040 '../../tools/gyp/v8.gyp:v8_libplatform',
Ben Murdochb0fe1622011-05-05 13:52:32 +010041 ],
42 'include_dirs': [
Ben Murdochb8a8cc12014-11-26 15:28:44 +000043 '../..',
Ben Murdochb0fe1622011-05-05 13:52:32 +010044 ],
Ben Murdochb8a8cc12014-11-26 15:28:44 +000045 'sources': [ ### gcmole(all) ###
Ben Murdoch3fb3ca82011-12-02 17:19:32 +000046 '<(generated_file)',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000047 'compiler/c-signature.h',
48 'compiler/codegen-tester.cc',
49 'compiler/codegen-tester.h',
50 'compiler/function-tester.h',
51 'compiler/graph-builder-tester.cc',
52 'compiler/graph-builder-tester.h',
53 'compiler/graph-tester.h',
54 'compiler/simplified-graph-builder.cc',
55 'compiler/simplified-graph-builder.h',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040056 'compiler/test-basic-block-profiler.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000057 'compiler/test-branch-combine.cc',
58 'compiler/test-changes-lowering.cc',
59 'compiler/test-codegen-deopt.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040060 'compiler/test-control-reducer.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000061 'compiler/test-gap-resolver.cc',
62 'compiler/test-graph-reducer.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040063 'compiler/test-graph-visualizer.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000064 'compiler/test-instruction.cc',
65 'compiler/test-js-context-specialization.cc',
66 'compiler/test-js-constant-cache.cc',
67 'compiler/test-js-typed-lowering.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040068 'compiler/test-jump-threading.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000069 'compiler/test-linkage.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040070 'compiler/test-loop-assignment-analysis.cc',
71 'compiler/test-loop-analysis.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000072 'compiler/test-machine-operator-reducer.cc',
73 'compiler/test-node-algorithm.cc',
74 'compiler/test-node-cache.cc',
75 'compiler/test-node.cc',
76 'compiler/test-operator.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000077 'compiler/test-pipeline.cc',
78 'compiler/test-representation-change.cc',
79 'compiler/test-run-deopt.cc',
80 'compiler/test-run-inlining.cc',
81 'compiler/test-run-intrinsics.cc',
82 'compiler/test-run-jsbranches.cc',
83 'compiler/test-run-jscalls.cc',
84 'compiler/test-run-jsexceptions.cc',
85 'compiler/test-run-jsops.cc',
86 'compiler/test-run-machops.cc',
87 'compiler/test-run-properties.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040088 'compiler/test-run-stackcheck.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000089 'compiler/test-run-variables.cc',
90 'compiler/test-schedule.cc',
91 'compiler/test-scheduler.cc',
92 'compiler/test-simplified-lowering.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -040093 'compiler/test-typer.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +010094 'cctest.cc',
95 'gay-fixed.cc',
96 'gay-precision.cc',
97 'gay-shortest.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +000098 'print-extension.cc',
99 'profiler-extension.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100100 'test-accessors.cc',
101 'test-alloc.cc',
102 'test-api.cc',
103 'test-ast.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000104 'test-atomicops.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100105 'test-bignum.cc',
106 'test-bignum-dtoa.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400107 'test-bit-vector.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000108 'test-checks.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100109 'test-circular-queue.cc',
110 'test-compiler.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000111 'test-constantpool.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100112 'test-conversions.cc',
113 'test-cpu-profiler.cc',
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100114 'test-date.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100115 'test-debug.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000116 'test-declarative-accessors.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100117 'test-decls.cc',
118 'test-deoptimization.cc',
Ben Murdoch69a99ed2011-11-30 16:03:39 +0000119 'test-dictionary.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100120 'test-diy-fp.cc',
121 'test-double.cc',
122 'test-dtoa.cc',
123 'test-fast-dtoa.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400124 'test-feedback-vector.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100125 'test-fixed-dtoa.cc',
126 'test-flags.cc',
127 'test-func-name-inference.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000128 'test-gc-tracer.cc',
129 'test-global-handles.cc',
130 'test-global-object.cc',
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100131 'test-hashing.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100132 'test-hashmap.cc',
133 'test-heap.cc',
134 'test-heap-profiler.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000135 'test-hydrogen-types.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100136 'test-list.cc',
137 'test-liveedit.cc',
Ben Murdoch257744e2011-11-30 15:57:28 +0000138 'test-lockers.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100139 'test-log.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000140 'test-microtask-delivery.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100141 'test-mark-compact.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000142 'test-mementos.cc',
143 'test-object-observe.cc',
144 'test-ordered-hash-table.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100145 'test-parsing.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000146 'test-platform.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100147 'test-profile-generator.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000148 'test-random-number-generator.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100149 'test-regexp.cc',
150 'test-reloc-info.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000151 'test-representation.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400152 'test-sampler-api.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100153 'test-serialize.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100154 'test-spaces.cc',
155 'test-strings.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000156 'test-symbols.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100157 'test-strtod.cc',
158 'test-thread-termination.cc',
159 'test-threads.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400160 'test-transitions.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000161 'test-types.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100162 'test-unbound-queue.cc',
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400163 'test-unboxed-doubles.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000164 'test-unique.cc',
165 'test-unscopables-hidden-prototype.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100166 'test-utils.cc',
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100167 'test-version.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000168 'test-weakmaps.cc',
169 'test-weaksets.cc',
170 'test-weaktypedarrays.cc',
171 'trace-extension.cc'
Ben Murdochb0fe1622011-05-05 13:52:32 +0100172 ],
173 'conditions': [
174 ['v8_target_arch=="ia32"', {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000175 'sources': [ ### gcmole(arch:ia32) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100176 'test-assembler-ia32.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000177 'test-code-stubs.cc',
178 'test-code-stubs-ia32.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100179 'test-disasm-ia32.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000180 'test-macro-assembler-ia32.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100181 'test-log-stack-tracer.cc'
182 ],
183 }],
184 ['v8_target_arch=="x64"', {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000185 'sources': [ ### gcmole(arch:x64) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100186 'test-assembler-x64.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000187 'test-code-stubs.cc',
188 'test-code-stubs-x64.cc',
189 'test-disasm-x64.cc',
Ben Murdochb0fe1622011-05-05 13:52:32 +0100190 'test-macro-assembler-x64.cc',
191 'test-log-stack-tracer.cc'
192 ],
193 }],
194 ['v8_target_arch=="arm"', {
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000195 'sources': [ ### gcmole(arch:arm) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100196 'test-assembler-arm.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000197 'test-code-stubs.cc',
198 'test-code-stubs-arm.cc',
199 'test-disasm-arm.cc',
200 'test-macro-assembler-arm.cc'
Ben Murdochb0fe1622011-05-05 13:52:32 +0100201 ],
202 }],
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000203 ['v8_target_arch=="arm64"', {
204 'sources': [ ### gcmole(arch:arm64) ###
205 'test-utils-arm64.cc',
206 'test-assembler-arm64.cc',
207 'test-code-stubs.cc',
208 'test-code-stubs-arm64.cc',
209 'test-disasm-arm64.cc',
210 'test-fuzz-arm64.cc',
211 'test-javascript-arm64.cc',
212 'test-js-arm64-variables.cc'
213 ],
214 }],
215 ['v8_target_arch=="mipsel"', {
216 'sources': [ ### gcmole(arch:mipsel) ###
Ben Murdochb0fe1622011-05-05 13:52:32 +0100217 'test-assembler-mips.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000218 'test-code-stubs.cc',
219 'test-code-stubs-mips.cc',
Ben Murdoch257744e2011-11-30 15:57:28 +0000220 'test-disasm-mips.cc',
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000221 'test-macro-assembler-mips.cc'
Ben Murdochb0fe1622011-05-05 13:52:32 +0100222 ],
223 }],
Ben Murdochb8a8cc12014-11-26 15:28:44 +0000224 ['v8_target_arch=="mips64el"', {
225 'sources': [
226 'test-assembler-mips64.cc',
227 'test-code-stubs.cc',
228 'test-code-stubs-mips64.cc',
229 'test-disasm-mips64.cc',
230 'test-macro-assembler-mips64.cc'
231 ],
232 }],
233 ['v8_target_arch=="x87"', {
234 'sources': [ ### gcmole(arch:x87) ###
235 'test-assembler-x87.cc',
236 'test-code-stubs.cc',
237 'test-code-stubs-x87.cc',
238 'test-disasm-x87.cc',
239 'test-macro-assembler-x87.cc',
240 'test-log-stack-tracer.cc'
241 ],
242 }],
243 [ 'OS=="linux" or OS=="qnx"', {
Ben Murdochb0fe1622011-05-05 13:52:32 +0100244 'sources': [
245 'test-platform-linux.cc',
246 ],
247 }],
Ben Murdochb0fe1622011-05-05 13:52:32 +0100248 [ 'OS=="win"', {
249 'sources': [
250 'test-platform-win32.cc',
251 ],
Ben Murdoch3ef787d2012-04-12 10:51:47 +0100252 'msvs_settings': {
253 'VCCLCompilerTool': {
254 # MSVS wants this for gay-{precision,shortest}.cc.
255 'AdditionalOptions': ['/bigobj'],
256 },
257 },
Ben Murdochb0fe1622011-05-05 13:52:32 +0100258 }],
Ben Murdoch589d6972011-11-30 16:04:58 +0000259 ['component=="shared_library"', {
260 # cctest can't be built against a shared library, so we need to
261 # depend on the underlying static target in that case.
262 'conditions': [
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400263 ['v8_use_snapshot=="true" and v8_use_external_startup_data==0', {
Ben Murdoch589d6972011-11-30 16:04:58 +0000264 'dependencies': ['../../tools/gyp/v8.gyp:v8_snapshot'],
Emily Bernierd0a1eb72015-03-24 16:35:39 -0400265 }],
266 ['v8_use_snapshot=="true" and v8_use_external_startup_data==1', {
267 'dependencies': ['../../tools/gyp/v8.gyp:v8_external_snapshot'],
268 }],
269 ['v8_use_snapshot!="true"', {
270 'dependencies': ['../../tools/gyp/v8.gyp:v8_nosnapshot'],
Ben Murdoch589d6972011-11-30 16:04:58 +0000271 }],
272 ],
273 }, {
274 'dependencies': ['../../tools/gyp/v8.gyp:v8'],
275 }],
Ben Murdochb0fe1622011-05-05 13:52:32 +0100276 ],
277 },
Ben Murdoch3fb3ca82011-12-02 17:19:32 +0000278 {
279 'target_name': 'resources',
280 'type': 'none',
281 'variables': {
282 'file_list': [
283 '../../tools/splaytree.js',
284 '../../tools/codemap.js',
285 '../../tools/csvparser.js',
286 '../../tools/consarray.js',
287 '../../tools/profile.js',
288 '../../tools/profile_view.js',
289 '../../tools/logreader.js',
290 'log-eq-of-logging-and-traversal.js',
291 ],
292 },
293 'actions': [
294 {
295 'action_name': 'js2c',
296 'inputs': [
297 '../../tools/js2c.py',
298 '<@(file_list)',
299 ],
300 'outputs': [
301 '<(generated_file)',
302 ],
303 'action': [
304 'python',
305 '../../tools/js2c.py',
306 '<@(_outputs)',
307 'TEST', # type
Ben Murdoch3fb3ca82011-12-02 17:19:32 +0000308 '<@(file_list)',
309 ],
310 }
311 ],
312 },
Ben Murdochb0fe1622011-05-05 13:52:32 +0100313 ],
314}