Index: third_party/WebKit/Source/devtools/BUILD.gn |
diff --git a/third_party/WebKit/Source/devtools/BUILD.gn b/third_party/WebKit/Source/devtools/BUILD.gn |
index ba26940eb249845dc3d9fd249e538b8114db63e9..fb13ceca0d0e849882273659f00aa5b33e41ac46 100644 |
--- a/third_party/WebKit/Source/devtools/BUILD.gn |
+++ b/third_party/WebKit/Source/devtools/BUILD.gn |
@@ -66,11 +66,47 @@ all_devtools_files = |
resources_out_dir_no_slash = "$root_out_dir/resources/inspector" |
resources_out_dir = resources_out_dir_no_slash + "/" |
+resources_test_release_dir = "$root_out_dir/resources/inspector_release/" |
+ |
generated_scripts = [ |
resources_out_dir + "InspectorBackendCommands.js", |
resources_out_dir + "SupportedCSSProperties.js", |
] |
+build_application_outputs = [ |
+ "inspector.js", |
+ "toolbox.js", |
+ "formatter_worker.js", |
+ "heap_snapshot_worker.js", |
+ "temp_storage_shared_worker.js", |
+ "accessibility/accessibility_module.js", |
+ "animation/animation_module.js", |
+ "audits/audits_module.js", |
+ "cm_modes/cm_modes_module.js", |
+ "components_lazy/components_lazy_module.js", |
+ "console/console_module.js", |
+ "devices/devices_module.js", |
+ "diff/diff_module.js", |
+ "elements/elements_module.js", |
+ "emulated_devices/emulated_devices_module.js", |
+ "es_tree/es_tree_module.js", |
+ "gonzales/gonzales_module.js", |
+ "layers/layers_module.js", |
+ "network/network_module.js", |
+ "profiler/profiler_module.js", |
+ "resources/resources_module.js", |
+ "sass/sass_module.js", |
+ "screencast/screencast_module.js", |
+ "security/security_module.js", |
+ "settings/settings_module.js", |
+ "snippets/snippets_module.js", |
+ "source_frame/source_frame_module.js", |
+ "sources/sources_module.js", |
+ "timeline_model/timeline_model_module.js", |
+ "timeline/timeline_module.js", |
+ "ui_lazy/ui_lazy_module.js", |
+] |
+ |
#------------------------------------------------------------------------------- |
visibility = [ "//third_party/WebKit/*" ] |
@@ -78,6 +114,7 @@ visibility = [ "//third_party/WebKit/*" ] |
group("devtools_frontend_resources") { |
public_deps = [ |
":build_applications", |
+ ":build_release_for_test", |
":copy_embedder_scripts", |
":copy_emulated_devices_images", |
":copy_inspector_images", |
@@ -269,39 +306,9 @@ action("build_applications") { |
debug_mode = "1" |
} else { |
- outputs += [ |
- resources_out_dir + "inspector.js", |
- resources_out_dir + "toolbox.js", |
- resources_out_dir + "formatter_worker.js", |
- resources_out_dir + "heap_snapshot_worker.js", |
- resources_out_dir + "temp_storage_shared_worker.js", |
- resources_out_dir + "accessibility/accessibility_module.js", |
- resources_out_dir + "animation/animation_module.js", |
- resources_out_dir + "audits/audits_module.js", |
- resources_out_dir + "cm_modes/cm_modes_module.js", |
- resources_out_dir + "components_lazy/components_lazy_module.js", |
- resources_out_dir + "console/console_module.js", |
- resources_out_dir + "devices/devices_module.js", |
- resources_out_dir + "diff/diff_module.js", |
- resources_out_dir + "elements/elements_module.js", |
- resources_out_dir + "emulated_devices/emulated_devices_module.js", |
- resources_out_dir + "es_tree/es_tree_module.js", |
- resources_out_dir + "gonzales/gonzales_module.js", |
- resources_out_dir + "layers/layers_module.js", |
- resources_out_dir + "network/network_module.js", |
- resources_out_dir + "profiler/profiler_module.js", |
- resources_out_dir + "resources/resources_module.js", |
- resources_out_dir + "sass/sass_module.js", |
- resources_out_dir + "screencast/screencast_module.js", |
- resources_out_dir + "security/security_module.js", |
- resources_out_dir + "settings/settings_module.js", |
- resources_out_dir + "snippets/snippets_module.js", |
- resources_out_dir + "source_frame/source_frame_module.js", |
- resources_out_dir + "sources/sources_module.js", |
- resources_out_dir + "timeline_model/timeline_model_module.js", |
- resources_out_dir + "timeline/timeline_module.js", |
- resources_out_dir + "ui_lazy/ui_lazy_module.js", |
- ] |
+ foreach(output, build_application_outputs) { |
+ outputs += [ resources_out_dir + output ] |
+ } |
debug_mode = "0" |
} |
@@ -321,6 +328,88 @@ action("build_applications") { |
] |
} |
+action("build_release_for_test") { |
pfeldman
2016/08/24 00:36:04
Why don't we reuse regular release build here?
chenwilliam
2016/08/24 22:53:40
Done.
|
+ script = "scripts/build_applications.py" |
+ helper_scripts = [ |
+ "scripts/modular_build.py", |
+ "scripts/concatenate_application_code.py", |
+ "scripts/rjsmin.py", |
+ ] |
+ |
+ generated_scripts_release = [ |
+ resources_test_release_dir + "InspectorBackendCommands.js", |
+ resources_test_release_dir + "SupportedCSSProperties.js", |
+ ] |
+ |
+ inputs = helper_scripts + all_devtools_files + generated_scripts_release + [ |
+ "front_end/inspector.html", |
+ "front_end/toolbox.html", |
+ ] |
+ |
+ outputs = [ |
+ resources_test_release_dir + "inspector.html", |
+ resources_test_release_dir + "toolbox.html", |
+ ] |
+ |
+ deps = [ |
+ ":frontend_protocol_sources_release", |
+ ":supported_css_properties_release", |
+ ] |
+ |
+ foreach(output, build_application_outputs) { |
+ outputs += [ resources_test_release_dir + output ] |
+ } |
+ |
+ debug_mode = "0" |
+ |
+ args = [ |
+ "inspector", |
+ "toolbox", |
+ "formatter_worker", |
+ "heap_snapshot_worker", |
+ "temp_storage_shared_worker", |
+ "--input_path", |
+ rebase_path("front_end", root_build_dir), |
+ "--output_path", |
+ rebase_path(resources_test_release_dir, root_build_dir), |
+ "--debug", |
+ debug_mode, |
+ ] |
+} |
+ |
+action("supported_css_properties_release") { |
chenwilliam
2016/08/19 23:52:39
I copied the actions for SupportedCSSProperties an
|
+ script = "scripts/generate_supported_css.py" |
+ |
+ inputs = [ |
+ "../core/css/CSSProperties.in", |
+ ] |
+ |
+ outputs = [ |
+ resources_test_release_dir + "SupportedCSSProperties.js", |
+ ] |
+ |
+ args = |
+ rebase_path(inputs, root_build_dir) + rebase_path(outputs, root_build_dir) |
+} |
+ |
+action("frontend_protocol_sources_release") { |
+ script = "scripts/CodeGeneratorFrontend.py" |
+ deps = [ |
+ "../core/inspector:protocol_version", |
+ ] |
+ inputs = [ |
+ "$blink_core_output_dir/inspector/protocol.json", |
+ ] |
+ outputs = [ |
+ resources_test_release_dir + "InspectorBackendCommands.js", |
+ ] |
+ |
+ args = rebase_path(inputs, root_build_dir) + [ |
+ "--output_js_dir", |
+ rebase_path(resources_test_release_dir, root_build_dir), |
+ ] |
+} |
+ |
if (debug_devtools) { |
# Debug: copy non-module directories and core into resources_out_dir as-is. |
group("copy_debug_non_modules") { |