blob: d6170d22739c7d5a23e601ec14860cb145649a6d [file] [log] [blame]
ager@chromium.org3a37e9b2009-04-27 09:26:21 +00001# Copyright 2009 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:
sgjesse@chromium.org755c5b12009-05-29 11:04:38 +00005#
ager@chromium.org3a37e9b2009-04-27 09:26:21 +00006# * 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.
sgjesse@chromium.org755c5b12009-05-29 11:04:38 +000015#
ager@chromium.org3a37e9b2009-04-27 09:26:21 +000016# 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 'chromium_code': 1,
31 'msvs_use_common_release': 0,
kasperl@chromium.org71affb52009-05-26 05:44:31 +000032 'gcc_version%': 'unknown',
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +000033 'base_source_files': [
34 '../../src/arm/assembler-arm-inl.h',
35 '../../src/arm/assembler-arm.cc',
36 '../../src/arm/assembler-arm.h',
37 '../../src/arm/builtins-arm.cc',
38 '../../src/arm/codegen-arm.cc',
39 '../../src/arm/codegen-arm.h',
40 '../../src/arm/constants-arm.h',
41 '../../src/arm/cpu-arm.cc',
42 '../../src/arm/debug-arm.cc',
43 '../../src/arm/disasm-arm.cc',
44 '../../src/arm/frames-arm.cc',
45 '../../src/arm/frames-arm.h',
46 '../../src/arm/ic-arm.cc',
47 '../../src/arm/jump-target-arm.cc',
48 '../../src/arm/macro-assembler-arm.cc',
49 '../../src/arm/macro-assembler-arm.h',
50 '../../src/arm/regexp-macro-assembler-arm.cc',
51 '../../src/arm/regexp-macro-assembler-arm.h',
52 '../../src/arm/register-allocator-arm.cc',
53 '../../src/arm/simulator-arm.cc',
54 '../../src/arm/stub-cache-arm.cc',
55 '../../src/arm/virtual-frame-arm.cc',
56 '../../src/arm/virtual-frame-arm.h',
57 '../../src/ia32/assembler-ia32-inl.h',
58 '../../src/ia32/assembler-ia32.cc',
59 '../../src/ia32/assembler-ia32.h',
60 '../../src/ia32/builtins-ia32.cc',
61 '../../src/ia32/codegen-ia32.cc',
62 '../../src/ia32/codegen-ia32.h',
63 '../../src/ia32/cpu-ia32.cc',
64 '../../src/ia32/debug-ia32.cc',
65 '../../src/ia32/disasm-ia32.cc',
66 '../../src/ia32/frames-ia32.cc',
67 '../../src/ia32/frames-ia32.h',
68 '../../src/ia32/ic-ia32.cc',
69 '../../src/ia32/jump-target-ia32.cc',
70 '../../src/ia32/macro-assembler-ia32.cc',
71 '../../src/ia32/macro-assembler-ia32.h',
72 '../../src/ia32/regexp-macro-assembler-ia32.cc',
73 '../../src/ia32/regexp-macro-assembler-ia32.h',
74 '../../src/ia32/register-allocator-ia32.cc',
75 '../../src/ia32/stub-cache-ia32.cc',
76 '../../src/ia32/virtual-frame-ia32.cc',
77 '../../src/ia32/virtual-frame-ia32.h',
78 '../../src/third_party/dtoa/dtoa.c',
79 '../../src/accessors.cc',
80 '../../src/accessors.h',
81 '../../src/allocation.cc',
82 '../../src/allocation.h',
83 '../../src/api.cc',
84 '../../src/api.h',
85 '../../src/apiutils.h',
86 '../../src/arguments.h',
87 '../../src/assembler.cc',
88 '../../src/assembler.h',
89 '../../src/ast.cc',
90 '../../src/ast.h',
91 '../../src/bootstrapper.cc',
92 '../../src/bootstrapper.h',
93 '../../src/builtins.cc',
94 '../../src/builtins.h',
95 '../../src/bytecodes-irregexp.h',
96 '../../src/char-predicates-inl.h',
97 '../../src/char-predicates.h',
98 '../../src/checks.cc',
99 '../../src/checks.h',
100 '../../src/code-stubs.cc',
101 '../../src/code-stubs.h',
102 '../../src/code.h',
103 '../../src/codegen-inl.h',
104 '../../src/codegen.cc',
105 '../../src/codegen.h',
106 '../../src/compilation-cache.cc',
107 '../../src/compilation-cache.h',
108 '../../src/compiler.cc',
109 '../../src/compiler.h',
110 '../../src/contexts.cc',
111 '../../src/contexts.h',
112 '../../src/conversions-inl.h',
113 '../../src/conversions.cc',
114 '../../src/conversions.h',
115 '../../src/counters.cc',
116 '../../src/counters.h',
117 '../../src/cpu.h',
118 '../../src/dateparser.cc',
119 '../../src/dateparser.h',
120 '../../src/dateparser-inl.h',
121 '../../src/debug.cc',
122 '../../src/debug.h',
123 '../../src/debug-agent.cc',
124 '../../src/debug-agent.h',
125 '../../src/disasm.h',
126 '../../src/disassembler.cc',
127 '../../src/disassembler.h',
128 '../../src/dtoa-config.c',
129 '../../src/execution.cc',
130 '../../src/execution.h',
131 '../../src/factory.cc',
132 '../../src/factory.h',
133 '../../src/flag-definitions.h',
134 '../../src/flags.cc',
135 '../../src/flags.h',
136 '../../src/frames-inl.h',
137 '../../src/frames.cc',
138 '../../src/frames.h',
139 '../../src/frame-element.h',
140 '../../src/func-name-inferrer.cc',
141 '../../src/func-name-inferrer.h',
142 '../../src/global-handles.cc',
143 '../../src/global-handles.h',
144 '../../src/globals.h',
145 '../../src/handles-inl.h',
146 '../../src/handles.cc',
147 '../../src/handles.h',
148 '../../src/hashmap.cc',
149 '../../src/hashmap.h',
150 '../../src/heap-inl.h',
151 '../../src/heap.cc',
152 '../../src/heap.h',
153 '../../src/ic-inl.h',
154 '../../src/ic.cc',
155 '../../src/ic.h',
156 '../../src/interpreter-irregexp.cc',
157 '../../src/interpreter-irregexp.h',
158 '../../src/jump-target.cc',
159 '../../src/jump-target.h',
160 '../../src/jump-target-inl.h',
161 '../../src/jsregexp-inl.h',
162 '../../src/jsregexp.cc',
163 '../../src/jsregexp.h',
164 '../../src/list-inl.h',
165 '../../src/list.h',
166 '../../src/log.cc',
167 '../../src/log-inl.h',
168 '../../src/log.h',
169 '../../src/log-utils.cc',
170 '../../src/log-utils.h',
171 '../../src/macro-assembler.h',
172 '../../src/mark-compact.cc',
173 '../../src/mark-compact.h',
174 '../../src/memory.h',
175 '../../src/messages.cc',
176 '../../src/messages.h',
177 '../../src/natives.h',
178 '../../src/objects-debug.cc',
179 '../../src/objects-inl.h',
180 '../../src/objects.cc',
181 '../../src/objects.h',
182 '../../src/oprofile-agent.h',
183 '../../src/oprofile-agent.cc',
184 '../../src/parser.cc',
185 '../../src/parser.h',
186 '../../src/platform-freebsd.cc',
187 '../../src/platform-linux.cc',
188 '../../src/platform-macos.cc',
189 '../../src/platform-nullos.cc',
190 '../../src/platform-posix.cc',
191 '../../src/platform-win32.cc',
192 '../../src/platform.h',
193 '../../src/prettyprinter.cc',
194 '../../src/prettyprinter.h',
195 '../../src/property.cc',
196 '../../src/property.h',
197 '../../src/regexp-macro-assembler-irregexp-inl.h',
198 '../../src/regexp-macro-assembler-irregexp.cc',
199 '../../src/regexp-macro-assembler-irregexp.h',
200 '../../src/regexp-macro-assembler-tracer.cc',
201 '../../src/regexp-macro-assembler-tracer.h',
202 '../../src/regexp-macro-assembler.cc',
203 '../../src/regexp-macro-assembler.h',
204 '../../src/regexp-stack.cc',
205 '../../src/regexp-stack.h',
206 '../../src/register-allocator.h',
207 '../../src/register-allocator-inl.h',
208 '../../src/register-allocator.cc',
209 '../../src/rewriter.cc',
210 '../../src/rewriter.h',
211 '../../src/runtime.cc',
212 '../../src/runtime.h',
213 '../../src/scanner.cc',
214 '../../src/scanner.h',
215 '../../src/scopeinfo.cc',
216 '../../src/scopeinfo.h',
217 '../../src/scopes.cc',
218 '../../src/scopes.h',
219 '../../src/serialize.cc',
220 '../../src/serialize.h',
221 '../../src/shell.h',
222 '../../src/smart-pointer.h',
223 '../../src/snapshot-common.cc',
224 '../../src/snapshot.h',
225 '../../src/spaces-inl.h',
226 '../../src/spaces.cc',
227 '../../src/spaces.h',
228 '../../src/string-stream.cc',
229 '../../src/string-stream.h',
230 '../../src/stub-cache.cc',
231 '../../src/stub-cache.h',
232 '../../src/token.cc',
233 '../../src/token.h',
234 '../../src/top.cc',
235 '../../src/top.h',
236 '../../src/unicode-inl.h',
237 '../../src/unicode.cc',
238 '../../src/unicode.h',
239 '../../src/usage-analyzer.cc',
240 '../../src/usage-analyzer.h',
241 '../../src/utils.cc',
242 '../../src/utils.h',
243 '../../src/v8-counters.cc',
244 '../../src/v8-counters.h',
245 '../../src/v8.cc',
246 '../../src/v8.h',
247 '../../src/v8threads.cc',
248 '../../src/v8threads.h',
249 '../../src/variables.cc',
250 '../../src/variables.h',
251 '../../src/version.cc',
252 '../../src/version.h',
253 '../../src/virtual-frame.h',
254 '../../src/virtual-frame.cc',
255 '../../src/zone-inl.h',
256 '../../src/zone.cc',
257 '../../src/zone.h',
258 ],
259 'not_base_source_files': [
260 # These files are #included by others and are not meant to be compiled
261 # directly.
262 '../../src/third_party/dtoa/dtoa.c',
263 ],
264 'd8_source_files': [
265 '../../src/d8-debug.cc',
266 '../../src/d8-posix.cc',
267 '../../src/d8-readline.cc',
268 '../../src/d8-windows.cc',
269 '../../src/d8.cc',
270 ],
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000271 },
272 'includes': [
273 '../../../build/common.gypi',
274 ],
275 'target_defaults': {
276 'defines': [
277 'ENABLE_LOGGING_AND_PROFILING',
278 ],
279 'configurations': {
280 'Debug': {
281 'defines': [
282 'DEBUG',
283 '_DEBUG',
284 'ENABLE_DISASSEMBLER',
285 ],
286 'msvs_settings': {
287 'VCCLCompilerTool': {
288 'Optimizations': '0',
289 'RuntimeLibrary': '1',
290 },
291 'VCLinkerTool': {
292 'LinkIncremental': '2',
293 },
294 },
295 },
296 'Release': {
297 'conditions': [
298 ['OS=="linux"', {
299 'cflags!': [
300 '-O2',
301 ],
302 'cflags': [
303 '-fomit-frame-pointer',
304 '-O3',
305 ],
kasperl@chromium.org71affb52009-05-26 05:44:31 +0000306 'conditions': [
307 [ 'gcc_version=="44"', {
308 'cflags': [
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000309 # Avoid gcc 4.4 strict aliasing issues in dtoa.c
310 '-fno-strict-aliasing',
311 # Avoid crashes with gcc 4.4 in the v8 test suite.
312 '-fno-tree-vrp',
kasperl@chromium.org71affb52009-05-26 05:44:31 +0000313 ],
314 }],
315 ],
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000316 'cflags_cc': [
317 '-fno-rtti',
318 ],
319 }],
320 ['OS=="win"', {
321 'msvs_configuration_attributes': {
322 'OutputDirectory': '$(SolutionDir)$(ConfigurationName)',
323 'IntermediateDirectory': '$(OutDir)\\obj\\$(ProjectName)',
324 'CharacterSet': '1',
325 },
326 'msvs_settings': {
327 'VCCLCompilerTool': {
328 'RuntimeLibrary': '0',
329 'Optimizations': '2',
330 'InlineFunctionExpansion': '2',
331 'EnableIntrinsicFunctions': 'true',
332 'FavorSizeOrSpeed': '0',
333 'OmitFramePointers': 'true',
334 'StringPooling': 'true',
335 },
336 'VCLinkerTool': {
337 'LinkIncremental': '1',
338 'OptimizeReferences': '2',
339 'OptimizeForWindows98': '1',
340 'EnableCOMDATFolding': '2',
341 },
342 },
343 }],
344 ],
345 },
346 },
347 'xcode_settings': {
348 'GCC_ENABLE_CPP_EXCEPTIONS': 'NO',
349 'GCC_ENABLE_CPP_RTTI': 'NO',
350 },
351 },
352 'targets': [
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000353 # Targets that apply to any architecture.
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000354 {
355 'target_name': 'js2c',
356 'type': 'none',
357 'variables': {
358 'library_files': [
359 '../../src/runtime.js',
360 '../../src/v8natives.js',
361 '../../src/array.js',
362 '../../src/string.js',
363 '../../src/uri.js',
364 '../../src/math.js',
365 '../../src/messages.js',
366 '../../src/apinatives.js',
367 '../../src/debug-delay.js',
368 '../../src/mirror-delay.js',
369 '../../src/date-delay.js',
370 '../../src/json-delay.js',
371 '../../src/regexp-delay.js',
372 '../../src/macros.py',
373 ],
374 },
375 'actions': [
376 {
377 'action_name': 'js2c',
378 'inputs': [
379 '../../tools/js2c.py',
380 '<@(library_files)',
381 ],
382 'outputs': [
383 '<(SHARED_INTERMEDIATE_DIR)/libraries.cc',
384 '<(SHARED_INTERMEDIATE_DIR)/libraries-empty.cc',
385 ],
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000386 'action': ['python', '../../tools/js2c.py', '<@(_outputs)', 'CORE', '<@(library_files)'],
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000387 },
388 ],
389 },
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000390 {
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000391 'target_name': 'd8_js2c',
392 'type': 'none',
393 'variables': {
394 'library_files': [
395 '../../src/d8.js',
396 '../../src/macros.py',
397 ],
398 },
399 'actions': [
400 {
401 'action_name': 'js2c',
402 'inputs': [
403 '../../tools/js2c.py',
404 '<@(library_files)',
405 ],
406 'extra_inputs': [
407 ],
408 'outputs': [
409 '<(SHARED_INTERMEDIATE_DIR)/d8-js.cc',
410 '<(SHARED_INTERMEDIATE_DIR)/d8-js-empty.cc',
411 ],
412 'action': ['python', '../../tools/js2c.py', '<@(_outputs)', 'D8', '<@(library_files)'],
413 },
414 ],
415 },
416
417 # Targets to build v8 for the native architecture (ia32).
418 {
419 'target_name': 'v8_base',
420 'type': '<(library)',
421 'defines': [
422 'V8_TARGET_ARCH_IA32',
423 'V8_NATIVE_REGEXP'
424 ],
425 'include_dirs+': [
426 '../../src',
427 '../../src/ia32',
428 ],
429 'msvs_guid': 'EC8B7909-62AF-470D-A75D-E1D89C837142',
430 'sources': [
431 '<@(base_source_files)',
432 ],
433 'sources!': [
434 '<@(not_base_source_files)',
435 ],
436 'sources/': [
437 ['exclude', '-arm\\.cc$'],
438 ['exclude', 'src/platform-.*\\.cc$' ],
439 ],
440 'conditions': [
441 ['OS=="linux"',
442 {
443 'link_settings': {
444 'libraries': [
445 # Needed for clock_gettime() used by src/platform-linux.cc.
446 '-lrt',
447 ],
448 },
449 'sources/': [
450 ['include', 'src/platform-linux\\.cc$'],
451 ['include', 'src/platform-posix\\.cc$']
452 ]
453 }
454 ],
455 ['OS=="mac"',
456 {
457 'sources/': [
458 ['include', 'src/platform-macos\\.cc$'],
459 ['include', 'src/platform-posix\\.cc$']
460 ]
461 }
462 ],
463 ['OS=="win"', {
464 'sources/': [['include', 'src/platform-win32\\.cc$']],
465 # 4355, 4800 came from common.vsprops
466 # 4018, 4244 were a per file config on dtoa-config.c
467 # TODO: It's probably possible and desirable to stop disabling the
468 # dtoa-specific warnings by modifying dtoa as was done in Chromium
469 # r9255. Refer to that revision for details.
470 'msvs_disabled_warnings': [4355, 4800, 4018, 4244],
471 'link_settings': {
472 'libraries': [ '-lwinmm.lib' ],
473 },
474 }],
475 ],
476 },
477 {
478 'target_name': 'v8_nosnapshot',
479 'type': '<(library)',
480 'defines': [
481 'V8_TARGET_ARCH_IA32',
482 'V8_NATIVE_REGEXP'
483 ],
484 'dependencies': [
485 'js2c',
486 'v8_base',
487 ],
488 'include_dirs': [
489 '../../src',
490 ],
491 'sources': [
492 '<(SHARED_INTERMEDIATE_DIR)/libraries.cc',
493 '../../src/snapshot-empty.cc',
494 ],
495 'export_dependent_settings': [
496 'v8_base',
497 ],
498 },
499 {
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000500 'target_name': 'mksnapshot',
501 'type': 'executable',
502 'dependencies': [
503 'v8_nosnapshot',
504 ],
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000505 'msvs_guid': '865575D0-37E2-405E-8CBA-5F6C485B5A26',
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000506 'sources': [
507 '../../src/mksnapshot.cc',
508 ],
509 },
510 {
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000511 'target_name': 'v8',
512 'type': '<(library)',
513 'defines': [
514 'V8_TARGET_ARCH_IA32',
515 'V8_NATIVE_REGEXP'
516 ],
517 'dependencies': [
518 'js2c',
519 'mksnapshot',
520 'v8_base',
521 ],
522 'msvs_guid': '21E22961-22BF-4493-BD3A-868F93DA5179',
523 'actions': [
524 {
525 'action_name': 'mksnapshot',
526 'inputs': [
527 '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
528 ],
529 'outputs': [
530 '<(INTERMEDIATE_DIR)/snapshot.cc',
531 ],
532 'action': ['<@(_inputs)', '<@(_outputs)'],
533 },
534 ],
535 'include_dirs': [
536 '../../src',
537 ],
538 'sources': [
539 '<(SHARED_INTERMEDIATE_DIR)/libraries-empty.cc',
540 '<(INTERMEDIATE_DIR)/snapshot.cc',
541 ],
542 'direct_dependent_settings': {
543 'include_dirs': [
544 '../../include',
545 ],
546 },
547 'export_dependent_settings': [
548 'v8_base',
549 ],
550 },
551 {
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000552 'target_name': 'v8_shell',
553 'type': 'executable',
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000554 'defines': [
555 'V8_TARGET_ARCH_IA32',
556 'V8_NATIVE_REGEXP'
557 ],
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000558 'dependencies': [
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000559 'v8',
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000560 ],
561 'sources': [
562 '../../samples/shell.cc',
563 ],
564 'conditions': [
565 [ 'OS=="win"', {
566 # This could be gotten by not setting chromium_code, if that's OK.
567 'defines': ['_CRT_SECURE_NO_WARNINGS'],
568 }],
569 ],
570 },
571 ],
kasperl@chromium.org3a2bafb2009-07-09 07:03:57 +0000572
573 'conditions': [ ['OS=="mac"', { 'targets': [
574 # TODO(bradnelson): temporarily disable 'd8' target on Windows while
575 # we work fix the performance regressions.
576 # TODO(sgk): temporarily disable 'd8' target on Linux while
577 # we work out getting the readline library on all the systems.
578 {
579 'target_name': 'd8',
580 'type': 'executable',
581 'dependencies': [
582 'd8_js2c',
583 'v8',
584 ],
585 'defines': [
586 'V8_TARGET_ARCH_IA32',
587 'V8_NATIVE_REGEXP'
588 ],
589 'include_dirs': [
590 '../../src',
591 ],
592 'sources': [
593 '<(SHARED_INTERMEDIATE_DIR)/d8-js.cc',
594 '<@(d8_source_files)',
595 ],
596 'conditions': [
597 [ 'OS=="linux"', {
598 'sources!': [ '../../src/d8-windows.cc' ],
599 'link_settings': { 'libraries': [ '-lreadline' ] },
600 }],
601 [ 'OS=="mac"', {
602 'sources!': [ '../../src/d8-windows.cc' ],
603 'link_settings': { 'libraries': [
604 '$(SDKROOT)/usr/lib/libreadline.dylib'
605 ]},
606 }],
607 [ 'OS=="win"', {
608 'sources!': [ '../../src/d8-readline.cc', '../../src/d8-posix.cc' ],
609 }],
610 ],
611 },
612 # TODO(sgk): temporarily disable the arm targets on Linux while
613 # we work out how to refactor the generator and/or add configuration
614 # settings to the .gyp file to handle building both variants in
615 # the same output directory.
616 #
617 # ARM targets, to test ARM code generation. These use an ARM simulator
618 # (src/simulator-arm.cc). The ARM targets are not snapshot-enabled.
619 {
620 'target_name': 'v8_arm',
621 'type': '<(library)',
622 'dependencies': [
623 'js2c',
624 ],
625 'defines': [
626 'V8_TARGET_ARCH_ARM',
627 ],
628 'include_dirs+': [
629 '../../src',
630 '../../src/arm',
631 ],
632 'sources': [
633 '<@(base_source_files)',
634 '<(SHARED_INTERMEDIATE_DIR)/libraries.cc',
635 '../../src/snapshot-empty.cc',
636 ],
637 'sources!': [
638 '<@(not_base_source_files)',
639 ],
640 'sources/': [
641 ['exclude', '-ia32\\.cc$'],
642 ['exclude', 'src/platform-.*\\.cc$' ],
643 ],
644 'direct_dependent_settings': {
645 'include_dirs': [
646 '../../include',
647 ],
648 },
649 'conditions': [
650 ['OS=="linux"',
651 {
652 'sources/': [
653 ['include', 'src/platform-linux\\.cc$'],
654 ['include', 'src/platform-posix\\.cc$']
655 ]
656 }
657 ],
658 ['OS=="mac"',
659 {
660 'sources/': [
661 ['include', 'src/platform-macos\\.cc$'],
662 ['include', 'src/platform-posix\\.cc$']
663 ]
664 }
665 ],
666 ['OS=="win"', {
667 'sources/': [['include', 'src/platform-win32\\.cc$']],
668 # 4355, 4800 came from common.vsprops
669 # 4018, 4244 were a per file config on dtoa-config.c
670 # TODO: It's probably possible and desirable to stop disabling the
671 # dtoa-specific warnings by modifying dtoa as was done in Chromium
672 # r9255. Refer to that revision for details.
673 'msvs_disabled_warnings': [4355, 4800, 4018, 4244],
674 }],
675 ],
676 },
677 {
678 'target_name': 'v8_shell_arm',
679 'type': 'executable',
680 'dependencies': [
681 'v8_arm',
682 ],
683 'defines': [
684 'V8_TARGET_ARCH_ARM',
685 ],
686 'sources': [
687 '../../samples/shell.cc',
688 ],
689 'conditions': [
690 [ 'OS=="win"', {
691 # This could be gotten by not setting chromium_code, if that's OK.
692 'defines': ['_CRT_SECURE_NO_WARNINGS'],
693 }],
694 ],
695 },
696 {
697 'target_name': 'd8_arm',
698 'type': 'executable',
699 'dependencies': [
700 'd8_js2c',
701 'v8_arm',
702 ],
703 'defines': [
704 'V8_TARGET_ARCH_ARM',
705 ],
706 'include_dirs': [
707 '../../src',
708 ],
709 'sources': [
710 '<(SHARED_INTERMEDIATE_DIR)/d8-js.cc',
711 '<@(d8_source_files)',
712 ],
713 'conditions': [
714 [ 'OS=="linux"', {
715 'sources!': [ '../../src/d8-windows.cc' ],
716 'link_settings': { 'libraries': [ '-lreadline' ] },
717 }],
718 [ 'OS=="mac"', {
719 'sources!': [ '../../src/d8-windows.cc' ],
720 'link_settings': { 'libraries': [
721 '$(SDKROOT)/usr/lib/libreadline.dylib'
722 ]},
723 }],
724 [ 'OS=="win"', {
725 'sources!': [ '../../src/d8-readline.cc', '../../src/d8-posix.cc' ],
726 }],
727 ],
728 },
729 ]}], # OS != "linux" (temporary, TODO(sgk))
730
731
732 ['OS=="win"', {
733 'target_defaults': {
734 'defines': [
735 '_USE_32BIT_TIME_T',
736 '_CRT_SECURE_NO_DEPRECATE',
737 '_CRT_NONSTDC_NO_DEPRECATE',
738 ],
739 'msvs_settings': {
740 'VCLinkerTool': {
741 'AdditionalOptions': '/IGNORE:4221 /NXCOMPAT',
742 },
743 },
744 },
745 }],
746 ],
ager@chromium.org3a37e9b2009-04-27 09:26:21 +0000747}