| Index: BUILD.gn
|
| diff --git a/BUILD.gn b/BUILD.gn
|
| index cab8f7317f619e8d225c8a2584a14ba53809637f..498fe872de56fe3ef2903f934d8bcb426fe2cdd2 100644
|
| --- a/BUILD.gn
|
| +++ b/BUILD.gn
|
| @@ -51,9 +51,6 @@ declare_args() {
|
| # Sets -dOBJECT_PRINT.
|
| v8_object_print = false
|
|
|
| - # Turns on compiler optimizations in V8 in Debug build.
|
| - v8_optimized_debug = true
|
| -
|
| # With post mortem support enabled, metadata is embedded into libv8 that
|
| # describes various parameters of the VM for use by debuggers. See
|
| # tools/gen-postmortem-metadata.py for details.
|
| @@ -303,33 +300,6 @@ config("toolchain") {
|
| }
|
|
|
| ###############################################################################
|
| -# Templates
|
| -#
|
| -
|
| -template("v8_source_set") {
|
| - source_set(target_name) {
|
| - forward_variables_from(invoker, "*", [ "configs" ])
|
| - configs += invoker.configs
|
| - configs -= [ "//build/config/compiler:chromium_code" ]
|
| - configs += [ "//build/config/compiler:no_chromium_code" ]
|
| - configs += [
|
| - ":features",
|
| - ":toolchain",
|
| - ]
|
| -
|
| - # TODO(machenbach): This config doesn't affect executables and components.
|
| - # It should be moved to a common place.
|
| - if (is_debug && !v8_optimized_debug) {
|
| - configs -= [ "//build/config/compiler:default_optimization" ]
|
| - configs += [ "//build/config/compiler:no_optimize" ]
|
| - } else {
|
| - configs -= [ "//build/config/compiler:default_optimization" ]
|
| - configs += [ "//build/config/compiler:optimize_max" ]
|
| - }
|
| - }
|
| -}
|
| -
|
| -###############################################################################
|
| # Actions
|
| #
|
|
|
| @@ -2044,19 +2014,15 @@ v8_source_set("simple_fuzzer") {
|
| #
|
|
|
| if (current_toolchain == v8_snapshot_toolchain) {
|
| - executable("mksnapshot") {
|
| + v8_executable("mksnapshot") {
|
| visibility = [ ":*" ] # Only targets in this file can depend on this.
|
|
|
| sources = [
|
| "src/snapshot/mksnapshot.cc",
|
| ]
|
|
|
| - configs -= [ "//build/config/compiler:chromium_code" ]
|
| - configs += [ "//build/config/compiler:no_chromium_code" ]
|
| - configs += [
|
| + configs = [
|
| ":internal_config",
|
| - ":features",
|
| - ":toolchain",
|
| ]
|
|
|
| deps = [
|
| @@ -2103,7 +2069,7 @@ group("gn_all") {
|
| }
|
|
|
| if (is_component_build) {
|
| - component("v8") {
|
| + v8_component("v8") {
|
| sources = [
|
| "src/v8dll-main.cc",
|
| ]
|
| @@ -2113,12 +2079,8 @@ if (is_component_build) {
|
| ":v8_maybe_snapshot",
|
| ]
|
|
|
| - configs -= [ "//build/config/compiler:chromium_code" ]
|
| - configs += [ "//build/config/compiler:no_chromium_code" ]
|
| - configs += [
|
| + configs = [
|
| ":internal_config",
|
| - ":features",
|
| - ":toolchain",
|
| ]
|
|
|
| public_configs = [ ":external_config" ]
|
| @@ -2133,21 +2095,17 @@ if (is_component_build) {
|
| }
|
| }
|
|
|
| -executable("d8") {
|
| +v8_executable("d8") {
|
| sources = [
|
| "src/d8.cc",
|
| "src/d8.h",
|
| ]
|
|
|
| - configs -= [ "//build/config/compiler:chromium_code" ]
|
| - configs += [ "//build/config/compiler:no_chromium_code" ]
|
| - configs += [
|
| + configs = [
|
| # Note: don't use :internal_config here because this target will get
|
| # the :external_config applied to it by virtue of depending on :v8, and
|
| # you can't have both applied to the same target.
|
| ":internal_config_base",
|
| - ":features",
|
| - ":toolchain",
|
| ]
|
|
|
| deps = [
|
| @@ -2183,20 +2141,16 @@ v8_isolate_run("d8") {
|
| }
|
|
|
| if (want_v8_shell) {
|
| - executable("v8_shell") {
|
| + v8_executable("v8_shell") {
|
| sources = [
|
| "samples/shell.cc",
|
| ]
|
|
|
| - configs -= [ "//build/config/compiler:chromium_code" ]
|
| - configs += [ "//build/config/compiler:no_chromium_code" ]
|
| - configs += [
|
| + configs = [
|
| # Note: don't use :internal_config here because this target will get
|
| # the :external_config applied to it by virtue of depending on :v8, and
|
| # you can't have both applied to the same target.
|
| ":internal_config_base",
|
| - ":features",
|
| - ":toolchain",
|
| ]
|
|
|
| deps = [
|
| @@ -2215,14 +2169,14 @@ if (want_v8_shell) {
|
| template("v8_fuzzer") {
|
| name = target_name
|
| forward_variables_from(invoker, "*")
|
| - executable("v8_simple_" + name) {
|
| + v8_executable("v8_simple_" + name) {
|
| deps = [
|
| ":" + name,
|
| ":simple_fuzzer",
|
| "//build/win:default_exe_manifest",
|
| ]
|
|
|
| - configs += [ ":external_config" ]
|
| + configs = [ ":external_config" ]
|
| }
|
| }
|
|
|
|
|