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/dcheck_always_on.gni") | 7 import("//build/config/dcheck_always_on.gni") |
8 import("//build/config/mips.gni") | 8 import("//build/config/mips.gni") |
9 import("//build/config/sanitizers/sanitizers.gni") | 9 import("//build/config/sanitizers/sanitizers.gni") |
10 | 10 |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 | 108 |
109 ############################################################################### | 109 ############################################################################### |
110 # Configurations | 110 # Configurations |
111 # | 111 # |
112 config("internal_config") { | 112 config("internal_config") { |
113 visibility = [ ":*" ] # Only targets in this file can depend on this. | 113 visibility = [ ":*" ] # Only targets in this file can depend on this. |
114 | 114 |
115 include_dirs = [ "." ] | 115 include_dirs = [ "." ] |
116 | 116 |
117 if (is_component_build) { | 117 if (is_component_build) { |
118 defines = [ "BUILDING_V8_SHARED" ] | 118 defines = [ |
| 119 "V8_SHARED", |
| 120 "BUILDING_V8_SHARED", |
| 121 ] |
119 } | 122 } |
120 } | 123 } |
121 | 124 |
122 config("internal_config_base") { | 125 config("internal_config_base") { |
123 visibility = [ ":*" ] # Only targets in this file can depend on this. | 126 visibility = [ ":*" ] # Only targets in this file can depend on this. |
124 | 127 |
125 include_dirs = [ "." ] | 128 include_dirs = [ "." ] |
126 } | 129 } |
127 | 130 |
128 # This config should be applied to code using the libplatform. | 131 # This config should be applied to code using the libplatform. |
129 config("libplatform_config") { | 132 config("libplatform_config") { |
130 include_dirs = [ "include" ] | 133 include_dirs = [ "include" ] |
131 } | 134 } |
132 | 135 |
133 # This config should be applied to code using the libsampler. | 136 # This config should be applied to code using the libsampler. |
134 config("libsampler_config") { | 137 config("libsampler_config") { |
135 include_dirs = [ "include" ] | 138 include_dirs = [ "include" ] |
136 } | 139 } |
137 | 140 |
138 # This config should only be applied to code using V8 and not any V8 code | 141 # This config should only be applied to code using V8 and not any V8 code |
139 # itself. | 142 # itself. |
140 config("external_config") { | 143 config("external_config") { |
141 if (is_component_build) { | 144 if (is_component_build) { |
142 defines = [ "USING_V8_SHARED" ] | 145 defines = [ |
| 146 "V8_SHARED", |
| 147 "USING_V8_SHARED", |
| 148 ] |
143 } | 149 } |
144 include_dirs = [ "include" ] | 150 include_dirs = [ "include" ] |
145 if (v8_enable_inspector_override) { | 151 if (v8_enable_inspector_override) { |
146 include_dirs += [ "$target_gen_dir/include" ] | 152 include_dirs += [ "$target_gen_dir/include" ] |
147 } | 153 } |
148 libs = [] | 154 libs = [] |
149 if (is_android && current_toolchain != host_toolchain) { | 155 if (is_android && current_toolchain != host_toolchain) { |
150 libs += [ "log" ] | 156 libs += [ "log" ] |
151 } | 157 } |
152 } | 158 } |
(...skipping 2223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2376 public_deps = [ | 2382 public_deps = [ |
2377 ":v8_base", | 2383 ":v8_base", |
2378 ":v8_maybe_snapshot", | 2384 ":v8_maybe_snapshot", |
2379 ] | 2385 ] |
2380 public_configs = [ ":external_config" ] | 2386 public_configs = [ ":external_config" ] |
2381 } | 2387 } |
2382 } | 2388 } |
2383 | 2389 |
2384 v8_executable("d8") { | 2390 v8_executable("d8") { |
2385 sources = [ | 2391 sources = [ |
2386 "$target_gen_dir/d8-js.cc", | |
2387 "src/d8.cc", | 2392 "src/d8.cc", |
2388 "src/d8.h", | 2393 "src/d8.h", |
2389 ] | 2394 ] |
2390 | 2395 |
2391 configs = [ | 2396 configs = [ |
2392 # Note: don't use :internal_config here because this target will get | 2397 # Note: don't use :internal_config here because this target will get |
2393 # the :external_config applied to it by virtue of depending on :v8, and | 2398 # the :external_config applied to it by virtue of depending on :v8, and |
2394 # you can't have both applied to the same target. | 2399 # you can't have both applied to the same target. |
2395 ":internal_config_base", | 2400 ":internal_config_base", |
2396 ] | 2401 ] |
2397 | 2402 |
2398 deps = [ | 2403 deps = [ |
2399 ":d8_js2c", | 2404 ":d8_js2c", |
2400 ":v8", | 2405 ":v8", |
2401 ":v8_libplatform", | 2406 ":v8_libplatform", |
2402 "//build/config/sanitizers:deps", | 2407 "//build/config/sanitizers:deps", |
2403 "//build/win:default_exe_manifest", | 2408 "//build/win:default_exe_manifest", |
2404 ] | 2409 ] |
2405 | 2410 |
2406 # TODO(jochen): Add support for vtunejit. | 2411 # TODO(jochen): Add support for vtunejit. |
2407 | 2412 |
2408 if (is_posix) { | 2413 if (is_posix) { |
2409 sources += [ "src/d8-posix.cc" ] | 2414 sources += [ "src/d8-posix.cc" ] |
2410 } else if (is_win) { | 2415 } else if (is_win) { |
2411 sources += [ "src/d8-windows.cc" ] | 2416 sources += [ "src/d8-windows.cc" ] |
2412 } | 2417 } |
2413 | 2418 |
| 2419 if (!is_component_build) { |
| 2420 sources += [ "$target_gen_dir/d8-js.cc" ] |
| 2421 } |
2414 if (v8_enable_i18n_support) { | 2422 if (v8_enable_i18n_support) { |
2415 deps += [ "//third_party/icu" ] | 2423 deps += [ "//third_party/icu" ] |
2416 } | 2424 } |
2417 } | 2425 } |
2418 | 2426 |
2419 v8_isolate_run("d8") { | 2427 v8_isolate_run("d8") { |
2420 deps = [ | 2428 deps = [ |
2421 ":d8", | 2429 ":d8", |
2422 ] | 2430 ] |
2423 | 2431 |
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2774 ":fuzzer_support", | 2782 ":fuzzer_support", |
2775 ":lib_wasm_section_fuzzer", | 2783 ":lib_wasm_section_fuzzer", |
2776 ":wasm_module_runner", | 2784 ":wasm_module_runner", |
2777 ] | 2785 ] |
2778 | 2786 |
2779 configs = [ ":internal_config" ] | 2787 configs = [ ":internal_config" ] |
2780 } | 2788 } |
2781 | 2789 |
2782 v8_fuzzer("wasm_data_section_fuzzer") { | 2790 v8_fuzzer("wasm_data_section_fuzzer") { |
2783 } | 2791 } |
OLD | NEW |