| 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("//testing/test.gni") | 5 import("//testing/test.gni") |
| 6 import("//v8/gni/v8.gni") | 6 import("//v8/gni/v8.gni") |
| 7 | 7 |
| 8 # This is depended upon from the browser DLL on Windows, where V8 is not used, | 8 # This is depended upon from the browser DLL on Windows, where V8 is not used, |
| 9 # but features are enabled. This cannot depend on V8. | 9 # but features are enabled. This cannot depend on V8. |
| 10 component("gin_features") { | 10 component("gin_features") { |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 ] | 88 ] |
| 89 | 89 |
| 90 if (v8_use_external_startup_data) { | 90 if (v8_use_external_startup_data) { |
| 91 data = [ | 91 data = [ |
| 92 "$root_out_dir/natives_blob.bin", | 92 "$root_out_dir/natives_blob.bin", |
| 93 "$root_out_dir/snapshot_blob.bin", | 93 "$root_out_dir/snapshot_blob.bin", |
| 94 ] | 94 ] |
| 95 } | 95 } |
| 96 | 96 |
| 97 defines = [ "GIN_IMPLEMENTATION" ] | 97 defines = [ "GIN_IMPLEMENTATION" ] |
| 98 | |
| 99 public_deps = [ | 98 public_deps = [ |
| 100 "//base", | 99 "//base", |
| 101 "//v8", | 100 "//v8", |
| 102 ] | 101 ] |
| 102 |
| 103 deps = [ | 103 deps = [ |
| 104 ":gin_features", | 104 ":gin_features", |
| 105 "//base/third_party/dynamic_annotations", | 105 "//base/third_party/dynamic_annotations", |
| 106 "//crypto", | 106 "//crypto", |
| 107 ] | 107 ] |
| 108 | 108 |
| 109 if (is_mac) { | 109 if (is_mac) { |
| 110 libs = [ "CoreFoundation.framework" ] | 110 libs = [ "CoreFoundation.framework" ] |
| 111 } | 111 } |
| 112 | 112 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 123 "//base", | 123 "//base", |
| 124 "//base:i18n", | 124 "//base:i18n", |
| 125 "//build/config/sanitizers:deps", | 125 "//build/config/sanitizers:deps", |
| 126 "//build/win:default_exe_manifest", | 126 "//build/win:default_exe_manifest", |
| 127 "//v8", | 127 "//v8", |
| 128 ] | 128 ] |
| 129 | 129 |
| 130 configs += [ "//v8:external_startup_data" ] | 130 configs += [ "//v8:external_startup_data" ] |
| 131 } | 131 } |
| 132 | 132 |
| 133 group("v8_context_snapshot_for_blink") { |
| 134 public_deps = [ |
| 135 ":generate_v8_context_snapshot_for_blink", |
| 136 ] |
| 137 } |
| 138 |
| 139 action("generate_v8_context_snapshot_for_blink") { |
| 140 script = "run.py" |
| 141 output_file = "$root_out_dir/context_blob.bin" |
| 142 output_path = rebase_path(output_file, root_build_dir) |
| 143 |
| 144 args = [ |
| 145 "./" + rebase_path(get_label_info(":gin_blink_snapshot($host_toolchain)", |
| 146 "root_out_dir") + "/gin_blink_snapshot", |
| 147 root_build_dir), |
| 148 "--output_file=$output_path", |
| 149 ] |
| 150 |
| 151 outputs = [ |
| 152 output_file, |
| 153 ] |
| 154 |
| 155 deps = [ |
| 156 ":gin_blink_snapshot($host_toolchain)", |
| 157 ] |
| 158 } |
| 159 |
| 160 # This config disables a link time optimization which merge some pointers, |
| 161 # but we must keep duplicated entries in external references for V8 snapshot. |
| 162 config("disable_icf") { |
| 163 visibility = [ ":*" ] # Only targets in this file can depend on this. |
| 164 if (is_win) { |
| 165 ldflags = [ "/OPT:NOICF" ] |
| 166 } else if (is_posix && !is_mac) { |
| 167 ldflags = [ "-Wl,--icf=none" ] |
| 168 } |
| 169 } |
| 170 |
| 171 executable("gin_blink_snapshot") { |
| 172 sources = [ |
| 173 "shell/gin_prepare_main.cc", |
| 174 ] |
| 175 |
| 176 deps = [ |
| 177 ":gin", |
| 178 "//mojo/edk/system:system", |
| 179 "//third_party/WebKit/public:blink", |
| 180 "//v8", |
| 181 ] |
| 182 |
| 183 configs += [ |
| 184 "//v8:external_startup_data", |
| 185 ":disable_icf", |
| 186 ] |
| 187 } |
| 188 |
| 133 source_set("gin_test") { | 189 source_set("gin_test") { |
| 134 testonly = true | 190 testonly = true |
| 135 sources = [ | 191 sources = [ |
| 136 "test/file.cc", | 192 "test/file.cc", |
| 137 "test/file.h", | 193 "test/file.h", |
| 138 "test/file_runner.cc", | 194 "test/file_runner.cc", |
| 139 "test/file_runner.h", | 195 "test/file_runner.h", |
| 140 "test/gc.cc", | 196 "test/gc.cc", |
| 141 "test/gc.h", | 197 "test/gc.h", |
| 142 "test/gtest.cc", | 198 "test/gtest.cc", |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 192 "shell/hello_world.js", | 248 "shell/hello_world.js", |
| 193 "test/file_unittests.js", | 249 "test/file_unittests.js", |
| 194 "test/gtest_unittests.js", | 250 "test/gtest_unittests.js", |
| 195 "../OWNERS", | 251 "../OWNERS", |
| 196 ] | 252 ] |
| 197 | 253 |
| 198 data_deps = [ | 254 data_deps = [ |
| 199 ":gin_shell", | 255 ":gin_shell", |
| 200 ] | 256 ] |
| 201 } | 257 } |
| OLD | NEW |