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

Unified Diff: BUILD.gn

Issue 1350223004: Split the GN 'snapshot_toolchain' logic out into an include file. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: update license header Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | snapshot_toolchain.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: BUILD.gn
diff --git a/BUILD.gn b/BUILD.gn
index 8946d2a0067df254664f8c7a6ee9202ba8d04342..06d7ecfeaf771c8d78acadc5b9a6e9aea863796b 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -11,6 +11,8 @@ import("//build/config/sanitizers/sanitizers.gni")
# Chromium build.
import("//build/module_args/v8.gni")
+import("snapshot_toolchain.gni")
+
# TODO(jochen): These will need to be user-settable to support standalone V8
# builds.
v8_deprecation_warnings = false
@@ -35,24 +37,6 @@ if (is_msan) {
v8_target_arch = target_cpu
}
-# The snapshot needs to be compiled for the host, but compiled with
-# a toolchain that matches the bit-width of the target.
-#
-# TODO(GYP): For now we only support 32-bit little-endian target builds from an
-# x64 Linux host. Eventually we need to support all of the host/target
-# configurations v8 runs on.
-if (host_cpu == "x64" && host_os == "linux") {
- if (target_cpu == "arm" || target_cpu == "mipsel" || target_cpu == "x86") {
- snapshot_toolchain = "//build/toolchain/linux:clang_x86"
- } else if (target_cpu == "x64") {
- snapshot_toolchain = "//build/toolchain/linux:clang_x64"
- } else {
- assert(false, "Need environment for this arch")
- }
-} else {
- snapshot_toolchain = default_toolchain
-}
-
###############################################################################
# Configurations
#
@@ -1819,6 +1803,7 @@ if (is_component_build) {
}
if ((current_toolchain == host_toolchain && v8_toolset_for_d8 == "host") ||
+ (current_toolchain == snapshot_toolchain && v8_toolset_for_d8 == "host") ||
(current_toolchain != host_toolchain && v8_toolset_for_d8 == "target")) {
executable("d8") {
sources = [
« no previous file with comments | « no previous file | snapshot_toolchain.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698