OLD | NEW |
---|---|
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 import("//build/config/android/config.gni") | 5 import("//build/config/android/config.gni") |
6 import("//build/config/arm.gni") | 6 import("//build/config/arm.gni") |
7 import("//build/config/mips.gni") | 7 import("//build/config/mips.gni") |
8 | 8 |
9 # Because standalone V8 builds are not supported, assume this is part of a | 9 # Because standalone V8 builds are not supported, assume this is part of a |
10 # Chromium build. | 10 # Chromium build. |
(...skipping 15 matching lines...) Expand all Loading... | |
26 v8_random_seed = "314159265" | 26 v8_random_seed = "314159265" |
27 v8_toolset_for_d8 = "host" | 27 v8_toolset_for_d8 = "host" |
28 | 28 |
29 # The snapshot needs to be compiled for the host, but compiled with | 29 # The snapshot needs to be compiled for the host, but compiled with |
30 # a toolchain that matches the bit-width of the target. | 30 # a toolchain that matches the bit-width of the target. |
31 # | 31 # |
32 # TODO(GYP): For now we only support 32-bit little-endian target builds from an | 32 # TODO(GYP): For now we only support 32-bit little-endian target builds from an |
33 # x64 Linux host. Eventually we need to support all of the host/target | 33 # x64 Linux host. Eventually we need to support all of the host/target |
34 # configurations v8 runs on. | 34 # configurations v8 runs on. |
35 if (host_cpu == "x64" && host_os == "linux" && | 35 if (host_cpu == "x64" && host_os == "linux" && |
36 (target_cpu == "arm" || target_cpu == "mipsel" || target_cpu == "x86")) { | 36 (target_cpu == "arm" || target_cpu == "mipsel" || |
37 target_cpu == "mips64el" || target_cpu == "x86")) { | |
Dirk Pranke
2015/03/17 21:32:04
As discussed over chat, I don't think you want thi
wtc
2015/03/17 21:42:05
Done.
| |
37 snapshot_toolchain = "//build/toolchain/linux:clang_x86" | 38 snapshot_toolchain = "//build/toolchain/linux:clang_x86" |
38 } else { | 39 } else { |
39 snapshot_toolchain = default_toolchain | 40 snapshot_toolchain = default_toolchain |
40 } | 41 } |
41 | 42 |
42 ############################################################################### | 43 ############################################################################### |
43 # Configurations | 44 # Configurations |
44 # | 45 # |
45 config("internal_config") { | 46 config("internal_config") { |
46 visibility = [ ":*" ] # Only targets in this file can depend on this. | 47 visibility = [ ":*" ] # Only targets in this file can depend on this. |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
106 defines += [ "V8_USE_EXTERNAL_STARTUP_DATA" ] | 107 defines += [ "V8_USE_EXTERNAL_STARTUP_DATA" ] |
107 } | 108 } |
108 } | 109 } |
109 | 110 |
110 config("toolchain") { | 111 config("toolchain") { |
111 visibility = [ ":*" ] # Only targets in this file can depend on this. | 112 visibility = [ ":*" ] # Only targets in this file can depend on this. |
112 | 113 |
113 defines = [] | 114 defines = [] |
114 cflags = [] | 115 cflags = [] |
115 | 116 |
116 # TODO(jochen): Add support for arm subarchs, mips, mipsel. | 117 # TODO(jochen): Add support for arm subarchs, mips, mipsel, mips64el. |
wtc
2015/03/17 21:42:05
Jochen, Michael: does it make sense to add "mips64
| |
117 | 118 |
118 if (v8_target_arch == "arm") { | 119 if (v8_target_arch == "arm") { |
119 defines += [ "V8_TARGET_ARCH_ARM" ] | 120 defines += [ "V8_TARGET_ARCH_ARM" ] |
120 if (current_cpu == "arm") { | 121 if (current_cpu == "arm") { |
121 if (arm_version == 7) { | 122 if (arm_version == 7) { |
122 defines += [ "CAN_USE_ARMV7_INSTRUCTIONS" ] | 123 defines += [ "CAN_USE_ARMV7_INSTRUCTIONS" ] |
123 } | 124 } |
124 if (arm_fpu == "vfpv3-d16") { | 125 if (arm_fpu == "vfpv3-d16") { |
125 defines += [ "CAN_USE_VFP3_INSTRUCTIONS" ] | 126 defines += [ "CAN_USE_VFP3_INSTRUCTIONS" ] |
126 } else if (arm_fpu == "vfpv3") { | 127 } else if (arm_fpu == "vfpv3") { |
(...skipping 16 matching lines...) Expand all Loading... | |
143 "CAN_USE_VFP32DREGS", | 144 "CAN_USE_VFP32DREGS", |
144 "USE_EABI_HARDFLOAT=0", | 145 "USE_EABI_HARDFLOAT=0", |
145 ] | 146 ] |
146 } | 147 } |
147 | 148 |
148 # TODO(jochen): Add support for arm_test_noprobe. | 149 # TODO(jochen): Add support for arm_test_noprobe. |
149 } | 150 } |
150 if (v8_target_arch == "arm64") { | 151 if (v8_target_arch == "arm64") { |
151 defines += [ "V8_TARGET_ARCH_ARM64" ] | 152 defines += [ "V8_TARGET_ARCH_ARM64" ] |
152 } | 153 } |
154 if (v8_target_arch == "mipsel") { | |
155 defines += [ "V8_TARGET_ARCH_MIPS" ] | |
156 } | |
157 if (v8_target_arch == "mips64el") { | |
158 defines += [ "V8_TARGET_ARCH_MIPS64" ] | |
159 } | |
153 if (v8_target_arch == "x86") { | 160 if (v8_target_arch == "x86") { |
154 defines += [ "V8_TARGET_ARCH_IA32" ] | 161 defines += [ "V8_TARGET_ARCH_IA32" ] |
155 } | 162 } |
156 if (v8_target_arch == "x64") { | 163 if (v8_target_arch == "x64") { |
wtc
2015/03/17 21:16:01
Would you like me to change these to else if's?
| |
157 defines += [ "V8_TARGET_ARCH_X64" ] | 164 defines += [ "V8_TARGET_ARCH_X64" ] |
158 } | 165 } |
159 if (is_win) { | 166 if (is_win) { |
160 defines += [ "WIN32" ] | 167 defines += [ "WIN32" ] |
161 # TODO(jochen): Support v8_enable_prof. | 168 # TODO(jochen): Support v8_enable_prof. |
162 } | 169 } |
163 | 170 |
164 # TODO(jochen): Add support for compiling with simulators. | 171 # TODO(jochen): Add support for compiling with simulators. |
165 | 172 |
166 if (is_debug) { | 173 if (is_debug) { |
(...skipping 1417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1584 sources += [ | 1591 sources += [ |
1585 "src/d8-debug.cc", | 1592 "src/d8-debug.cc", |
1586 "$target_gen_dir/d8-js.cc", | 1593 "$target_gen_dir/d8-js.cc", |
1587 ] | 1594 ] |
1588 } | 1595 } |
1589 if (v8_enable_i18n_support) { | 1596 if (v8_enable_i18n_support) { |
1590 deps += [ "//third_party/icu" ] | 1597 deps += [ "//third_party/icu" ] |
1591 } | 1598 } |
1592 } | 1599 } |
1593 } | 1600 } |
OLD | NEW |