Commit a0aec7b2 authored by Michael Achenbach's avatar Michael Achenbach Committed by Commit Bot

[build] Split v8_base on static-library builds on windows

Bug: v8:6461
Change-Id: Iafabf2d53aa6492b78a9e5ae683f010453bb195d
Reviewed-on: https://chromium-review.googlesource.com/533014Reviewed-by: 's avatarJochen Eisinger <jochen@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#45922}
parent d701edfc
......@@ -1081,6 +1081,9 @@ v8_header_set("v8_headers") {
v8_source_set("v8_base") {
visibility = [ ":*" ] # Only targets in this file can depend on this.
# Split static libraries on windows into two.
split_count = 2
sources = [
"//base/trace_event/common/trace_event_common.h",
......
......@@ -4,6 +4,7 @@
import("//build/config/sanitizers/sanitizers.gni")
import("//build/config/v8_target_cpu.gni")
import("//build/split_static_library.gni")
declare_args() {
# Includes files needed for correctness fuzzing.
......@@ -91,20 +92,19 @@ if (is_posix && v8_enable_backtrace) {
# All templates should be kept in sync.
template("v8_source_set") {
if (defined(v8_static_library) && v8_static_library) {
static_library(target_name) {
forward_variables_from(invoker, "*", [ "configs" ])
configs += invoker.configs
configs -= v8_remove_configs
configs += v8_add_configs
}
if (defined(invoker.split_count) && invoker.split_count > 1 &&
defined(v8_static_library) && v8_static_library && is_win) {
link_target_type = "split_static_library"
} else if (defined(v8_static_library) && v8_static_library) {
link_target_type = "static_library"
} else {
source_set(target_name) {
forward_variables_from(invoker, "*", [ "configs" ])
configs += invoker.configs
configs -= v8_remove_configs
configs += v8_add_configs
}
link_target_type = "source_set"
}
target(link_target_type, target_name) {
forward_variables_from(invoker, "*", [ "configs" ])
configs += invoker.configs
configs -= v8_remove_configs
configs += v8_add_configs
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment