The data contained in this repository can be downloaded to your computer using one of several clients.
Please see the documentation of your version control software client for more information.

Please select the desired protocol below to get the URL.

This URL has Read-Only access.

Statistics
| Branch: | Revision:

main_repo / deps / v8 / tools / gyp / v8.gyp @ f230a1cf

History | View | Annotate | Download (35.5 KB)

1
# Copyright 2012 the V8 project authors. All rights reserved.
2
# 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
{
29
  'variables': {
30
    'v8_code': 1,
31
  },
32
  'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
33
  'targets': [
34
    {
35
      'target_name': 'v8',
36
      'dependencies_traverse': 1,
37
      'conditions': [
38
        ['want_separate_host_toolset==1', {
39
          'toolsets': ['host', 'target'],
40
        }, {
41
          'toolsets': ['target'],
42
        }],
43
        ['v8_use_snapshot=="true"', {
44
          # The dependency on v8_base should come from a transitive
45
          # dependency however the Android toolchain requires libv8_base.a
46
          # to appear before libv8_snapshot.a so it's listed explicitly.
47
          'dependencies': ['v8_base.<(v8_target_arch)', 'v8_snapshot'],
48
        },
49
        {
50
          # The dependency on v8_base should come from a transitive
51
          # dependency however the Android toolchain requires libv8_base.a
52
          # to appear before libv8_snapshot.a so it's listed explicitly.
53
          'dependencies': [
54
            'v8_base.<(v8_target_arch)',
55
            'v8_nosnapshot.<(v8_target_arch)',
56
          ],
57
        }],
58
        ['component=="shared_library"', {
59
          'type': '<(component)',
60
          'sources': [
61
            '../../src/defaults.cc',
62
            # Note: on non-Windows we still build this file so that gyp
63
            # has some sources to link into the component.
64
            '../../src/v8dll-main.cc',
65
          ],
66
          'defines': [
67
            'V8_SHARED',
68
            'BUILDING_V8_SHARED',
69
          ],
70
          'direct_dependent_settings': {
71
            'defines': [
72
              'V8_SHARED',
73
              'USING_V8_SHARED',
74
            ],
75
          },
76
          'target_conditions': [
77
            ['OS=="android" and _toolset=="target"', {
78
              'libraries': [
79
                '-llog',
80
              ],
81
              'include_dirs': [
82
                'src/common/android/include',
83
              ],
84
            }],
85
          ],
86
          'conditions': [
87
            ['OS=="mac"', {
88
              'xcode_settings': {
89
                'OTHER_LDFLAGS': ['-dynamiclib', '-all_load']
90
              },
91
            }],
92
            ['soname_version!=""', {
93
              'product_extension': 'so.<(soname_version)',
94
            }],
95
          ],
96
        },
97
        {
98
          'type': 'none',
99
        }],
100
      ],
101
      'direct_dependent_settings': {
102
        'include_dirs': [
103
          '../../include',
104
        ],
105
      },
106
    },
107
    {
108
      'target_name': 'v8_snapshot',
109
      'type': 'static_library',
110
      'conditions': [
111
        ['want_separate_host_toolset==1', {
112
          'toolsets': ['host', 'target'],
113
          'dependencies': [
114
            'mksnapshot.<(v8_target_arch)#host',
115
            'js2c#host',
116
          ],
117
        }, {
118
          'toolsets': ['target'],
119
          'dependencies': ['mksnapshot.<(v8_target_arch)', 'js2c'],
120
        }],
121
        ['component=="shared_library"', {
122
          'defines': [
123
            'V8_SHARED',
124
            'BUILDING_V8_SHARED',
125
          ],
126
          'direct_dependent_settings': {
127
            'defines': [
128
              'V8_SHARED',
129
              'USING_V8_SHARED',
130
            ],
131
          },
132
        }],
133
      ],
134
      'dependencies': [
135
        'v8_base.<(v8_target_arch)',
136
      ],
137
      'include_dirs+': [
138
        '../../src',
139
      ],
140
      'sources': [
141
        '<(SHARED_INTERMEDIATE_DIR)/libraries.cc',
142
        '<(SHARED_INTERMEDIATE_DIR)/experimental-libraries.cc',
143
        '<(INTERMEDIATE_DIR)/snapshot.cc',
144
      ],
145
      'actions': [
146
        {
147
          'action_name': 'run_mksnapshot',
148
          'inputs': [
149
            '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot.<(v8_target_arch)<(EXECUTABLE_SUFFIX)',
150
          ],
151
          'outputs': [
152
            '<(INTERMEDIATE_DIR)/snapshot.cc',
153
          ],
154
          'variables': {
155
            'mksnapshot_flags': [
156
              '--log-snapshot-positions',
157
              '--logfile', '<(INTERMEDIATE_DIR)/snapshot.log',
158
            ],
159
          },
160
          'action': [
161
            '<@(_inputs)',
162
            '<@(mksnapshot_flags)',
163
            '<@(_outputs)'
164
          ],
165
        },
166
      ],
167
    },
168
    {
169
      'target_name': 'v8_nosnapshot.<(v8_target_arch)',
170
      'type': 'static_library',
171
      'dependencies': [
172
        'v8_base.<(v8_target_arch)',
173
      ],
174
      'include_dirs+': [
175
        '../../src',
176
      ],
177
      'sources': [
178
        '<(SHARED_INTERMEDIATE_DIR)/libraries.cc',
179
        '<(SHARED_INTERMEDIATE_DIR)/experimental-libraries.cc',
180
        '../../src/snapshot-empty.cc',
181
      ],
182
      'conditions': [
183
        ['want_separate_host_toolset==1', {
184
          'toolsets': ['host', 'target'],
185
          'dependencies': ['js2c#host'],
186
        }, {
187
          'toolsets': ['target'],
188
          'dependencies': ['js2c'],
189
        }],
190
        ['component=="shared_library"', {
191
          'defines': [
192
            'BUILDING_V8_SHARED',
193
            'V8_SHARED',
194
          ],
195
        }],
196
      ]
197
    },
198
    {
199
      'target_name': 'v8_base.<(v8_target_arch)',
200
      'type': 'static_library',
201
      'variables': {
202
        'optimize': 'max',
203
      },
204
      'include_dirs+': [
205
        '../../src',
206
      ],
207
      'sources': [  ### gcmole(all) ###
208
        '../../src/accessors.cc',
209
        '../../src/accessors.h',
210
        '../../src/allocation.cc',
211
        '../../src/allocation.h',
212
        '../../src/allocation-site-scopes.cc',
213
        '../../src/allocation-site-scopes.h',
214
        '../../src/allocation-tracker.cc',
215
        '../../src/allocation-tracker.h',
216
        '../../src/api.cc',
217
        '../../src/api.h',
218
        '../../src/apiutils.h',
219
        '../../src/arguments.cc',
220
        '../../src/arguments.h',
221
        '../../src/assembler.cc',
222
        '../../src/assembler.h',
223
        '../../src/assert-scope.h',
224
        '../../src/ast.cc',
225
        '../../src/ast.h',
226
        '../../src/atomicops.h',
227
        '../../src/atomicops_internals_x86_gcc.cc',
228
        '../../src/bignum-dtoa.cc',
229
        '../../src/bignum-dtoa.h',
230
        '../../src/bignum.cc',
231
        '../../src/bignum.h',
232
        '../../src/bootstrapper.cc',
233
        '../../src/bootstrapper.h',
234
        '../../src/builtins.cc',
235
        '../../src/builtins.h',
236
        '../../src/bytecodes-irregexp.h',
237
        '../../src/cached-powers.cc',
238
        '../../src/cached-powers.h',
239
        '../../src/char-predicates-inl.h',
240
        '../../src/char-predicates.h',
241
        '../../src/checks.cc',
242
        '../../src/checks.h',
243
        '../../src/circular-queue-inl.h',
244
        '../../src/circular-queue.h',
245
        '../../src/code-stubs.cc',
246
        '../../src/code-stubs.h',
247
        '../../src/code-stubs-hydrogen.cc',
248
        '../../src/code.h',
249
        '../../src/codegen.cc',
250
        '../../src/codegen.h',
251
        '../../src/compilation-cache.cc',
252
        '../../src/compilation-cache.h',
253
        '../../src/compiler.cc',
254
        '../../src/compiler.h',
255
        '../../src/contexts.cc',
256
        '../../src/contexts.h',
257
        '../../src/conversions-inl.h',
258
        '../../src/conversions.cc',
259
        '../../src/conversions.h',
260
        '../../src/counters.cc',
261
        '../../src/counters.h',
262
        '../../src/cpu-profiler-inl.h',
263
        '../../src/cpu-profiler.cc',
264
        '../../src/cpu-profiler.h',
265
        '../../src/cpu.cc',
266
        '../../src/cpu.h',
267
        '../../src/data-flow.cc',
268
        '../../src/data-flow.h',
269
        '../../src/date.cc',
270
        '../../src/date.h',
271
        '../../src/dateparser-inl.h',
272
        '../../src/dateparser.cc',
273
        '../../src/dateparser.h',
274
        '../../src/debug-agent.cc',
275
        '../../src/debug-agent.h',
276
        '../../src/debug.cc',
277
        '../../src/debug.h',
278
        '../../src/deoptimizer.cc',
279
        '../../src/deoptimizer.h',
280
        '../../src/disasm.h',
281
        '../../src/disassembler.cc',
282
        '../../src/disassembler.h',
283
        '../../src/diy-fp.cc',
284
        '../../src/diy-fp.h',
285
        '../../src/double.h',
286
        '../../src/dtoa.cc',
287
        '../../src/dtoa.h',
288
        '../../src/effects.h',
289
        '../../src/elements-kind.cc',
290
        '../../src/elements-kind.h',
291
        '../../src/elements.cc',
292
        '../../src/elements.h',
293
        '../../src/execution.cc',
294
        '../../src/execution.h',
295
        '../../src/extensions/externalize-string-extension.cc',
296
        '../../src/extensions/externalize-string-extension.h',
297
        '../../src/extensions/gc-extension.cc',
298
        '../../src/extensions/gc-extension.h',
299
        '../../src/extensions/statistics-extension.cc',
300
        '../../src/extensions/statistics-extension.h',
301
        '../../src/factory.cc',
302
        '../../src/factory.h',
303
        '../../src/fast-dtoa.cc',
304
        '../../src/fast-dtoa.h',
305
        '../../src/fixed-dtoa.cc',
306
        '../../src/fixed-dtoa.h',
307
        '../../src/flag-definitions.h',
308
        '../../src/flags.cc',
309
        '../../src/flags.h',
310
        '../../src/frames-inl.h',
311
        '../../src/frames.cc',
312
        '../../src/frames.h',
313
        '../../src/full-codegen.cc',
314
        '../../src/full-codegen.h',
315
        '../../src/func-name-inferrer.cc',
316
        '../../src/func-name-inferrer.h',
317
        '../../src/gdb-jit.cc',
318
        '../../src/gdb-jit.h',
319
        '../../src/global-handles.cc',
320
        '../../src/global-handles.h',
321
        '../../src/globals.h',
322
        '../../src/handles-inl.h',
323
        '../../src/handles.cc',
324
        '../../src/handles.h',
325
        '../../src/hashmap.h',
326
        '../../src/heap-inl.h',
327
        '../../src/heap-profiler.cc',
328
        '../../src/heap-profiler.h',
329
        '../../src/heap-snapshot-generator-inl.h',
330
        '../../src/heap-snapshot-generator.cc',
331
        '../../src/heap-snapshot-generator.h',
332
        '../../src/heap.cc',
333
        '../../src/heap.h',
334
        '../../src/hydrogen-alias-analysis.h',
335
        '../../src/hydrogen-bce.cc',
336
        '../../src/hydrogen-bce.h',
337
        '../../src/hydrogen-bch.cc',
338
        '../../src/hydrogen-bch.h',
339
        '../../src/hydrogen-canonicalize.cc',
340
        '../../src/hydrogen-canonicalize.h',
341
        '../../src/hydrogen-check-elimination.cc',
342
        '../../src/hydrogen-check-elimination.h',
343
        '../../src/hydrogen-dce.cc',
344
        '../../src/hydrogen-dce.h',
345
        '../../src/hydrogen-dehoist.cc',
346
        '../../src/hydrogen-dehoist.h',
347
        '../../src/hydrogen-environment-liveness.cc',
348
        '../../src/hydrogen-environment-liveness.h',
349
        '../../src/hydrogen-escape-analysis.cc',
350
        '../../src/hydrogen-escape-analysis.h',
351
        '../../src/hydrogen-flow-engine.h',
352
        '../../src/hydrogen-instructions.cc',
353
        '../../src/hydrogen-instructions.h',
354
        '../../src/hydrogen.cc',
355
        '../../src/hydrogen.h',
356
        '../../src/hydrogen-gvn.cc',
357
        '../../src/hydrogen-gvn.h',
358
        '../../src/hydrogen-infer-representation.cc',
359
        '../../src/hydrogen-infer-representation.h',
360
        '../../src/hydrogen-infer-types.cc',
361
        '../../src/hydrogen-infer-types.h',
362
        '../../src/hydrogen-load-elimination.cc',
363
        '../../src/hydrogen-load-elimination.h',
364
        '../../src/hydrogen-mark-deoptimize.cc',
365
        '../../src/hydrogen-mark-deoptimize.h',
366
        '../../src/hydrogen-mark-unreachable.cc',
367
        '../../src/hydrogen-mark-unreachable.h',
368
        '../../src/hydrogen-minus-zero.cc',
369
        '../../src/hydrogen-minus-zero.h',
370
        '../../src/hydrogen-osr.cc',
371
        '../../src/hydrogen-osr.h',
372
        '../../src/hydrogen-range-analysis.cc',
373
        '../../src/hydrogen-range-analysis.h',
374
        '../../src/hydrogen-redundant-phi.cc',
375
        '../../src/hydrogen-redundant-phi.h',
376
        '../../src/hydrogen-removable-simulates.cc',
377
        '../../src/hydrogen-removable-simulates.h',
378
        '../../src/hydrogen-representation-changes.cc',
379
        '../../src/hydrogen-representation-changes.h',
380
        '../../src/hydrogen-sce.cc',
381
        '../../src/hydrogen-sce.h',
382
        '../../src/hydrogen-uint32-analysis.cc',
383
        '../../src/hydrogen-uint32-analysis.h',
384
        '../../src/i18n.cc',
385
        '../../src/i18n.h',
386
        '../../src/icu_util.cc',
387
        '../../src/icu_util.h',
388
        '../../src/ic-inl.h',
389
        '../../src/ic.cc',
390
        '../../src/ic.h',
391
        '../../src/incremental-marking.cc',
392
        '../../src/incremental-marking.h',
393
        '../../src/interface.cc',
394
        '../../src/interface.h',
395
        '../../src/interpreter-irregexp.cc',
396
        '../../src/interpreter-irregexp.h',
397
        '../../src/isolate.cc',
398
        '../../src/isolate.h',
399
        '../../src/json-parser.h',
400
        '../../src/json-stringifier.h',
401
        '../../src/jsregexp-inl.h',
402
        '../../src/jsregexp.cc',
403
        '../../src/jsregexp.h',
404
        '../../src/lazy-instance.h',
405
        '../../src/list-inl.h',
406
        '../../src/list.h',
407
        '../../src/lithium-allocator-inl.h',
408
        '../../src/lithium-allocator.cc',
409
        '../../src/lithium-allocator.h',
410
        '../../src/lithium-codegen.cc',
411
        '../../src/lithium-codegen.h',
412
        '../../src/lithium.cc',
413
        '../../src/lithium.h',
414
        '../../src/liveedit.cc',
415
        '../../src/liveedit.h',
416
        '../../src/log-inl.h',
417
        '../../src/log-utils.cc',
418
        '../../src/log-utils.h',
419
        '../../src/log.cc',
420
        '../../src/log.h',
421
        '../../src/macro-assembler.h',
422
        '../../src/mark-compact.cc',
423
        '../../src/mark-compact.h',
424
        '../../src/messages.cc',
425
        '../../src/messages.h',
426
        '../../src/natives.h',
427
        '../../src/objects-debug.cc',
428
        '../../src/objects-inl.h',
429
        '../../src/objects-printer.cc',
430
        '../../src/objects-visiting.cc',
431
        '../../src/objects-visiting.h',
432
        '../../src/objects.cc',
433
        '../../src/objects.h',
434
        '../../src/once.cc',
435
        '../../src/once.h',
436
        '../../src/optimizing-compiler-thread.h',
437
        '../../src/optimizing-compiler-thread.cc',
438
        '../../src/parser.cc',
439
        '../../src/parser.h',
440
        '../../src/platform/elapsed-timer.h',
441
        '../../src/platform/time.cc',
442
        '../../src/platform/time.h',
443
        '../../src/platform.h',
444
        '../../src/platform/condition-variable.cc',
445
        '../../src/platform/condition-variable.h',
446
        '../../src/platform/mutex.cc',
447
        '../../src/platform/mutex.h',
448
        '../../src/platform/semaphore.cc',
449
        '../../src/platform/semaphore.h',
450
        '../../src/platform/socket.cc',
451
        '../../src/platform/socket.h',
452
        '../../src/preparse-data-format.h',
453
        '../../src/preparse-data.cc',
454
        '../../src/preparse-data.h',
455
        '../../src/preparser.cc',
456
        '../../src/preparser.h',
457
        '../../src/prettyprinter.cc',
458
        '../../src/prettyprinter.h',
459
        '../../src/profile-generator-inl.h',
460
        '../../src/profile-generator.cc',
461
        '../../src/profile-generator.h',
462
        '../../src/property-details.h',
463
        '../../src/property.cc',
464
        '../../src/property.h',
465
        '../../src/regexp-macro-assembler-irregexp-inl.h',
466
        '../../src/regexp-macro-assembler-irregexp.cc',
467
        '../../src/regexp-macro-assembler-irregexp.h',
468
        '../../src/regexp-macro-assembler-tracer.cc',
469
        '../../src/regexp-macro-assembler-tracer.h',
470
        '../../src/regexp-macro-assembler.cc',
471
        '../../src/regexp-macro-assembler.h',
472
        '../../src/regexp-stack.cc',
473
        '../../src/regexp-stack.h',
474
        '../../src/rewriter.cc',
475
        '../../src/rewriter.h',
476
        '../../src/runtime-profiler.cc',
477
        '../../src/runtime-profiler.h',
478
        '../../src/runtime.cc',
479
        '../../src/runtime.h',
480
        '../../src/safepoint-table.cc',
481
        '../../src/safepoint-table.h',
482
        '../../src/sampler.cc',
483
        '../../src/sampler.h',
484
        '../../src/scanner-character-streams.cc',
485
        '../../src/scanner-character-streams.h',
486
        '../../src/scanner.cc',
487
        '../../src/scanner.h',
488
        '../../src/scopeinfo.cc',
489
        '../../src/scopeinfo.h',
490
        '../../src/scopes.cc',
491
        '../../src/scopes.h',
492
        '../../src/serialize.cc',
493
        '../../src/serialize.h',
494
        '../../src/small-pointer-list.h',
495
        '../../src/smart-pointers.h',
496
        '../../src/snapshot-common.cc',
497
        '../../src/snapshot.h',
498
        '../../src/spaces-inl.h',
499
        '../../src/spaces.cc',
500
        '../../src/spaces.h',
501
        '../../src/store-buffer-inl.h',
502
        '../../src/store-buffer.cc',
503
        '../../src/store-buffer.h',
504
        '../../src/string-search.cc',
505
        '../../src/string-search.h',
506
        '../../src/string-stream.cc',
507
        '../../src/string-stream.h',
508
        '../../src/strtod.cc',
509
        '../../src/strtod.h',
510
        '../../src/stub-cache.cc',
511
        '../../src/stub-cache.h',
512
        '../../src/sweeper-thread.h',
513
        '../../src/sweeper-thread.cc',
514
        '../../src/token.cc',
515
        '../../src/token.h',
516
        '../../src/transitions-inl.h',
517
        '../../src/transitions.cc',
518
        '../../src/transitions.h',
519
        '../../src/type-info.cc',
520
        '../../src/type-info.h',
521
        '../../src/types.cc',
522
        '../../src/types.h',
523
        '../../src/typing.cc',
524
        '../../src/typing.h',
525
        '../../src/unbound-queue-inl.h',
526
        '../../src/unbound-queue.h',
527
        '../../src/unicode-inl.h',
528
        '../../src/unicode.cc',
529
        '../../src/unicode.h',
530
        '../../src/unique.h',
531
        '../../src/uri.h',
532
        '../../src/utils-inl.h',
533
        '../../src/utils.cc',
534
        '../../src/utils.h',
535
        '../../src/utils/random-number-generator.cc',
536
        '../../src/utils/random-number-generator.h',
537
        '../../src/v8-counters.cc',
538
        '../../src/v8-counters.h',
539
        '../../src/v8.cc',
540
        '../../src/v8.h',
541
        '../../src/v8checks.h',
542
        '../../src/v8conversions.cc',
543
        '../../src/v8conversions.h',
544
        '../../src/v8globals.h',
545
        '../../src/v8memory.h',
546
        '../../src/v8threads.cc',
547
        '../../src/v8threads.h',
548
        '../../src/v8utils.cc',
549
        '../../src/v8utils.h',
550
        '../../src/variables.cc',
551
        '../../src/variables.h',
552
        '../../src/version.cc',
553
        '../../src/version.h',
554
        '../../src/vm-state-inl.h',
555
        '../../src/vm-state.h',
556
        '../../src/zone-inl.h',
557
        '../../src/zone.cc',
558
        '../../src/zone.h',
559
      ],
560
      'conditions': [
561
        ['want_separate_host_toolset==1', {
562
          'toolsets': ['host', 'target'],
563
        }, {
564
          'toolsets': ['target'],
565
        }],
566
        ['v8_target_arch=="arm"', {
567
          'sources': [  ### gcmole(arch:arm) ###
568
            '../../src/arm/assembler-arm-inl.h',
569
            '../../src/arm/assembler-arm.cc',
570
            '../../src/arm/assembler-arm.h',
571
            '../../src/arm/builtins-arm.cc',
572
            '../../src/arm/code-stubs-arm.cc',
573
            '../../src/arm/code-stubs-arm.h',
574
            '../../src/arm/codegen-arm.cc',
575
            '../../src/arm/codegen-arm.h',
576
            '../../src/arm/constants-arm.h',
577
            '../../src/arm/constants-arm.cc',
578
            '../../src/arm/cpu-arm.cc',
579
            '../../src/arm/debug-arm.cc',
580
            '../../src/arm/deoptimizer-arm.cc',
581
            '../../src/arm/disasm-arm.cc',
582
            '../../src/arm/frames-arm.cc',
583
            '../../src/arm/frames-arm.h',
584
            '../../src/arm/full-codegen-arm.cc',
585
            '../../src/arm/ic-arm.cc',
586
            '../../src/arm/lithium-arm.cc',
587
            '../../src/arm/lithium-arm.h',
588
            '../../src/arm/lithium-codegen-arm.cc',
589
            '../../src/arm/lithium-codegen-arm.h',
590
            '../../src/arm/lithium-gap-resolver-arm.cc',
591
            '../../src/arm/lithium-gap-resolver-arm.h',
592
            '../../src/arm/macro-assembler-arm.cc',
593
            '../../src/arm/macro-assembler-arm.h',
594
            '../../src/arm/regexp-macro-assembler-arm.cc',
595
            '../../src/arm/regexp-macro-assembler-arm.h',
596
            '../../src/arm/simulator-arm.cc',
597
            '../../src/arm/stub-cache-arm.cc',
598
          ],
599
        }],
600
        ['v8_target_arch=="ia32" or v8_target_arch=="mac" or OS=="mac"', {
601
          'sources': [  ### gcmole(arch:ia32) ###
602
            '../../src/ia32/assembler-ia32-inl.h',
603
            '../../src/ia32/assembler-ia32.cc',
604
            '../../src/ia32/assembler-ia32.h',
605
            '../../src/ia32/builtins-ia32.cc',
606
            '../../src/ia32/code-stubs-ia32.cc',
607
            '../../src/ia32/code-stubs-ia32.h',
608
            '../../src/ia32/codegen-ia32.cc',
609
            '../../src/ia32/codegen-ia32.h',
610
            '../../src/ia32/cpu-ia32.cc',
611
            '../../src/ia32/debug-ia32.cc',
612
            '../../src/ia32/deoptimizer-ia32.cc',
613
            '../../src/ia32/disasm-ia32.cc',
614
            '../../src/ia32/frames-ia32.cc',
615
            '../../src/ia32/frames-ia32.h',
616
            '../../src/ia32/full-codegen-ia32.cc',
617
            '../../src/ia32/ic-ia32.cc',
618
            '../../src/ia32/lithium-codegen-ia32.cc',
619
            '../../src/ia32/lithium-codegen-ia32.h',
620
            '../../src/ia32/lithium-gap-resolver-ia32.cc',
621
            '../../src/ia32/lithium-gap-resolver-ia32.h',
622
            '../../src/ia32/lithium-ia32.cc',
623
            '../../src/ia32/lithium-ia32.h',
624
            '../../src/ia32/macro-assembler-ia32.cc',
625
            '../../src/ia32/macro-assembler-ia32.h',
626
            '../../src/ia32/regexp-macro-assembler-ia32.cc',
627
            '../../src/ia32/regexp-macro-assembler-ia32.h',
628
            '../../src/ia32/stub-cache-ia32.cc',
629
          ],
630
        }],
631
        ['v8_target_arch=="mipsel"', {
632
          'sources': [  ### gcmole(arch:mipsel) ###
633
            '../../src/mips/assembler-mips.cc',
634
            '../../src/mips/assembler-mips.h',
635
            '../../src/mips/assembler-mips-inl.h',
636
            '../../src/mips/builtins-mips.cc',
637
            '../../src/mips/codegen-mips.cc',
638
            '../../src/mips/codegen-mips.h',
639
            '../../src/mips/code-stubs-mips.cc',
640
            '../../src/mips/code-stubs-mips.h',
641
            '../../src/mips/constants-mips.cc',
642
            '../../src/mips/constants-mips.h',
643
            '../../src/mips/cpu-mips.cc',
644
            '../../src/mips/debug-mips.cc',
645
            '../../src/mips/deoptimizer-mips.cc',
646
            '../../src/mips/disasm-mips.cc',
647
            '../../src/mips/frames-mips.cc',
648
            '../../src/mips/frames-mips.h',
649
            '../../src/mips/full-codegen-mips.cc',
650
            '../../src/mips/ic-mips.cc',
651
            '../../src/mips/lithium-codegen-mips.cc',
652
            '../../src/mips/lithium-codegen-mips.h',
653
            '../../src/mips/lithium-gap-resolver-mips.cc',
654
            '../../src/mips/lithium-gap-resolver-mips.h',
655
            '../../src/mips/lithium-mips.cc',
656
            '../../src/mips/lithium-mips.h',
657
            '../../src/mips/macro-assembler-mips.cc',
658
            '../../src/mips/macro-assembler-mips.h',
659
            '../../src/mips/regexp-macro-assembler-mips.cc',
660
            '../../src/mips/regexp-macro-assembler-mips.h',
661
            '../../src/mips/simulator-mips.cc',
662
            '../../src/mips/stub-cache-mips.cc',
663
          ],
664
        }],
665
        ['v8_target_arch=="x64" or v8_target_arch=="mac" or OS=="mac"', {
666
          'sources': [  ### gcmole(arch:x64) ###
667
            '../../src/x64/assembler-x64-inl.h',
668
            '../../src/x64/assembler-x64.cc',
669
            '../../src/x64/assembler-x64.h',
670
            '../../src/x64/builtins-x64.cc',
671
            '../../src/x64/code-stubs-x64.cc',
672
            '../../src/x64/code-stubs-x64.h',
673
            '../../src/x64/codegen-x64.cc',
674
            '../../src/x64/codegen-x64.h',
675
            '../../src/x64/cpu-x64.cc',
676
            '../../src/x64/debug-x64.cc',
677
            '../../src/x64/deoptimizer-x64.cc',
678
            '../../src/x64/disasm-x64.cc',
679
            '../../src/x64/frames-x64.cc',
680
            '../../src/x64/frames-x64.h',
681
            '../../src/x64/full-codegen-x64.cc',
682
            '../../src/x64/ic-x64.cc',
683
            '../../src/x64/lithium-codegen-x64.cc',
684
            '../../src/x64/lithium-codegen-x64.h',
685
            '../../src/x64/lithium-gap-resolver-x64.cc',
686
            '../../src/x64/lithium-gap-resolver-x64.h',
687
            '../../src/x64/lithium-x64.cc',
688
            '../../src/x64/lithium-x64.h',
689
            '../../src/x64/macro-assembler-x64.cc',
690
            '../../src/x64/macro-assembler-x64.h',
691
            '../../src/x64/regexp-macro-assembler-x64.cc',
692
            '../../src/x64/regexp-macro-assembler-x64.h',
693
            '../../src/x64/stub-cache-x64.cc',
694
          ],
695
        }],
696
        ['OS=="linux"', {
697
            'link_settings': {
698
              'conditions': [
699
                ['v8_compress_startup_data=="bz2"', {
700
                  'libraries': [
701
                    '-lbz2',
702
                  ]
703
                }],
704
              ],
705
              'libraries': [
706
                '-lrt'
707
              ]
708
            },
709
            'sources': [  ### gcmole(os:linux) ###
710
              '../../src/platform-linux.cc',
711
              '../../src/platform-posix.cc'
712
            ],
713
          }
714
        ],
715
        ['OS=="android"', {
716
            'defines': [
717
              'CAN_USE_VFP_INSTRUCTIONS',
718
            ],
719
            'sources': [
720
              '../../src/platform-posix.cc'
721
            ],
722
            'conditions': [
723
              ['host_os=="mac"', {
724
                'target_conditions': [
725
                  ['_toolset=="host"', {
726
                    'sources': [
727
                      '../../src/platform-macos.cc'
728
                    ]
729
                  }, {
730
                    'sources': [
731
                      '../../src/platform-linux.cc'
732
                    ]
733
                  }],
734
                ],
735
              }, {
736
                # TODO(bmeurer): What we really want here, is this:
737
                #
738
                # 'link_settings': {
739
                #   'target_conditions': [
740
                #     ['_toolset=="host"', {
741
                #       'libraries': [
742
                #         '-lrt'
743
                #       ]
744
                #     }]
745
                #   ]
746
                # },
747
                #
748
                # but we can't do this right now, as the AOSP does not support
749
                # linking against the host librt, so we need to work around this
750
                # for now, using the following hack (see platform/time.cc):
751
                'target_conditions': [
752
                  ['_toolset=="host"', {
753
                    'defines': [
754
                      'V8_LIBRT_NOT_AVAILABLE=1',
755
                    ],
756
                  }],
757
                ],
758
                'sources': [
759
                  '../../src/platform-linux.cc'
760
                ]
761
              }],
762
            ],
763
          },
764
        ],
765
        ['OS=="freebsd"', {
766
            'link_settings': {
767
              'libraries': [
768
                '-L/usr/local/lib -lexecinfo',
769
            ]},
770
            'sources': [
771
              '../../src/platform-freebsd.cc',
772
              '../../src/platform-posix.cc'
773
            ],
774
          }
775
        ],
776
        ['OS=="openbsd"', {
777
            'link_settings': {
778
              'libraries': [
779
                '-L/usr/local/lib -lexecinfo',
780
            ]},
781
            'sources': [
782
              '../../src/platform-openbsd.cc',
783
              '../../src/platform-posix.cc'
784
            ],
785
          }
786
        ],
787
        ['OS=="netbsd"', {
788
            'link_settings': {
789
              'libraries': [
790
                '-L/usr/pkg/lib -Wl,-R/usr/pkg/lib -lexecinfo',
791
            ]},
792
            'sources': [
793
              '../../src/platform-openbsd.cc',
794
              '../../src/platform-posix.cc'
795
            ],
796
          }
797
        ],
798
        ['OS=="solaris"', {
799
            'link_settings': {
800
              'libraries': [
801
                '-lsocket -lnsl',
802
            ]},
803
            'sources': [
804
              '../../src/platform-solaris.cc',
805
              '../../src/platform-posix.cc'
806
            ],
807
          }
808
        ],
809
        ['OS=="mac"', {
810
          'sources': [
811
            '../../src/platform-macos.cc',
812
            '../../src/platform-posix.cc'
813
          ]},
814
        ],
815
        ['OS=="win"', {
816
          'defines': [
817
            '_CRT_RAND_S'  # for rand_s()
818
          ],
819
          'variables': {
820
            'gyp_generators': '<!(echo $GYP_GENERATORS)',
821
          },
822
          'conditions': [
823
            ['gyp_generators=="make"', {
824
              'variables': {
825
                'build_env': '<!(uname -o)',
826
              },
827
              'conditions': [
828
                ['build_env=="Cygwin"', {
829
                  'sources': [
830
                    '../../src/platform-cygwin.cc',
831
                    '../../src/platform-posix.cc'
832
                  ],
833
                }, {
834
                  'sources': [
835
                    '../../src/platform-win32.cc',
836
                    '../../src/win32-math.cc',
837
                    '../../src/win32-math.h'
838
                  ],
839
                }],
840
              ],
841
              'link_settings':  {
842
                'libraries': [ '-lwinmm', '-lws2_32' ],
843
              },
844
            }, {
845
              'sources': [
846
                '../../src/platform-win32.cc',
847
                '../../src/win32-math.cc',
848
                '../../src/win32-math.h'
849
              ],
850
              'msvs_disabled_warnings': [4351, 4355, 4800],
851
              'link_settings':  {
852
                'libraries': [ '-lwinmm.lib', '-lws2_32.lib' ],
853
              },
854
            }],
855
          ],
856
        }],
857
        ['component=="shared_library"', {
858
          'defines': [
859
            'BUILDING_V8_SHARED',
860
            'V8_SHARED',
861
          ],
862
        }, {
863
          'sources': [
864
            '../../src/defaults.cc',
865
          ],
866
        }],
867
        ['v8_postmortem_support=="true"', {
868
          'sources': [
869
            '<(SHARED_INTERMEDIATE_DIR)/debug-support.cc',
870
          ]
871
        }],
872
        ['v8_enable_i18n_support==1', {
873
          'dependencies': [
874
            '<(icu_gyp_path):icui18n',
875
            '<(icu_gyp_path):icuuc',
876
          ]
877
        }, {  # v8_enable_i18n_support==0
878
          'sources!': [
879
            '../../src/i18n.cc',
880
            '../../src/i18n.h',
881
          ],
882
        }],
883
        ['OS=="win" and v8_enable_i18n_support==1', {
884
          'dependencies': [
885
            '<(icu_gyp_path):icudata',
886
          ],
887
        }],
888
      ],
889
    },
890
    {
891
      'target_name': 'js2c',
892
      'type': 'none',
893
      'conditions': [
894
        ['want_separate_host_toolset==1', {
895
          'toolsets': ['host'],
896
        }, {
897
          'toolsets': ['target'],
898
        }],
899
        ['v8_enable_i18n_support==1', {
900
          'variables': {
901
            'i18n_library_files': [
902
              '../../src/i18n.js',
903
            ],
904
          },
905
        }, {
906
          'variables': {
907
            'i18n_library_files': [],
908
          },
909
        }],
910
      ],
911
      'variables': {
912
        'library_files': [
913
          '../../src/runtime.js',
914
          '../../src/v8natives.js',
915
          '../../src/array.js',
916
          '../../src/string.js',
917
          '../../src/uri.js',
918
          '../../src/math.js',
919
          '../../src/messages.js',
920
          '../../src/apinatives.js',
921
          '../../src/debug-debugger.js',
922
          '../../src/mirror-debugger.js',
923
          '../../src/liveedit-debugger.js',
924
          '../../src/date.js',
925
          '../../src/json.js',
926
          '../../src/regexp.js',
927
          '../../src/arraybuffer.js',
928
          '../../src/typedarray.js',
929
          '../../src/macros.py',
930
        ],
931
        'experimental_library_files': [
932
          '../../src/macros.py',
933
          '../../src/symbol.js',
934
          '../../src/proxy.js',
935
          '../../src/collection.js',
936
          '../../src/object-observe.js',
937
          '../../src/generator.js',
938
          '../../src/array-iterator.js',
939
          '../../src/harmony-string.js',
940
          '../../src/harmony-array.js',
941
          '../../src/harmony-math.js'
942
        ],
943
      },
944
      'actions': [
945
        {
946
          'action_name': 'js2c',
947
          'inputs': [
948
            '../../tools/js2c.py',
949
            '<@(library_files)',
950
            '<@(i18n_library_files)',
951
          ],
952
          'outputs': [
953
            '<(SHARED_INTERMEDIATE_DIR)/libraries.cc',
954
          ],
955
          'action': [
956
            'python',
957
            '../../tools/js2c.py',
958
            '<@(_outputs)',
959
            'CORE',
960
            '<(v8_compress_startup_data)',
961
            '<@(library_files)',
962
            '<@(i18n_library_files)',
963
          ],
964
        },
965
        {
966
          'action_name': 'js2c_experimental',
967
          'inputs': [
968
            '../../tools/js2c.py',
969
            '<@(experimental_library_files)',
970
          ],
971
          'outputs': [
972
            '<(SHARED_INTERMEDIATE_DIR)/experimental-libraries.cc',
973
          ],
974
          'action': [
975
            'python',
976
            '../../tools/js2c.py',
977
            '<@(_outputs)',
978
            'EXPERIMENTAL',
979
            '<(v8_compress_startup_data)',
980
            '<@(experimental_library_files)'
981
          ],
982
        },
983
      ],
984
    },
985
    {
986
      'target_name': 'postmortem-metadata',
987
      'type': 'none',
988
      'variables': {
989
        'heapobject_files': [
990
            '../../src/objects.h',
991
            '../../src/objects-inl.h',
992
        ],
993
      },
994
      'actions': [
995
          {
996
            'action_name': 'gen-postmortem-metadata',
997
            'inputs': [
998
              '../../tools/gen-postmortem-metadata.py',
999
              '<@(heapobject_files)',
1000
            ],
1001
            'outputs': [
1002
              '<(SHARED_INTERMEDIATE_DIR)/debug-support.cc',
1003
            ],
1004
            'action': [
1005
              'python',
1006
              '../../tools/gen-postmortem-metadata.py',
1007
              '<@(_outputs)',
1008
              '<@(heapobject_files)'
1009
            ]
1010
          }
1011
        ]
1012
    },
1013
    {
1014
      'target_name': 'mksnapshot.<(v8_target_arch)',
1015
      'type': 'executable',
1016
      'dependencies': [
1017
        'v8_base.<(v8_target_arch)',
1018
        'v8_nosnapshot.<(v8_target_arch)',
1019
      ],
1020
      'include_dirs+': [
1021
        '../../src',
1022
      ],
1023
      'sources': [
1024
        '../../src/mksnapshot.cc',
1025
      ],
1026
      'conditions': [
1027
        ['want_separate_host_toolset==1', {
1028
          'toolsets': ['host'],
1029
        }, {
1030
          'toolsets': ['target'],
1031
        }],
1032
        ['v8_compress_startup_data=="bz2"', {
1033
          'libraries': [
1034
            '-lbz2',
1035
          ]
1036
        }],
1037
      ],
1038
    },
1039
    {
1040
      'target_name': 'v8_shell',
1041
      'type': 'executable',
1042
      'dependencies': [
1043
        'v8'
1044
      ],
1045
      'sources': [
1046
        '../../samples/shell.cc',
1047
      ],
1048
      'conditions': [
1049
        ['want_separate_host_toolset==1', {
1050
          'toolsets': ['host'],
1051
        }, {
1052
          'toolsets': ['target'],
1053
        }],
1054
        ['OS=="win"', {
1055
          # This could be gotten by not setting chromium_code, if that's OK.
1056
          'defines': ['_CRT_SECURE_NO_WARNINGS'],
1057
        }],
1058
        ['v8_compress_startup_data=="bz2"', {
1059
          'libraries': [
1060
            '-lbz2',
1061
          ]
1062
        }],
1063
      ],
1064
    },
1065
  ],
1066
}