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/features.gni") | |
6 | |
5 gypi_values = exec_script( | 7 gypi_values = exec_script( |
6 "//build/gypi_to_gn.py", | 8 "//build/gypi_to_gn.py", |
7 [ rebase_path("devtools.gypi") ], | 9 [ rebase_path("devtools.gypi") ], |
8 "scope", | 10 "scope", |
9 [ "devtools.gypi" ]) | 11 [ "devtools.gypi" ]) |
10 | 12 |
11 # Some of the files in the .gypi use GYP variable expansions, go through and | 13 # Some of the files in the .gypi use GYP variable expansions, go through and |
12 # fix them. | 14 # fix them. |
13 devtools_core_base_files = gypi_values.devtools_core_base_files - [ | 15 devtools_core_base_files = gypi_values.devtools_core_base_files - [ |
14 "<@(devtools_standalone_files)", | 16 "<@(devtools_standalone_files)", |
15 ] + gypi_values.devtools_standalone_files | 17 ] + gypi_values.devtools_standalone_files |
16 | 18 |
17 devtools_core_files = | 19 devtools_core_files = |
18 devtools_core_base_files + | 20 devtools_core_base_files + |
19 gypi_values.devtools_bindings_js_files + | 21 gypi_values.devtools_bindings_js_files + |
20 gypi_values.devtools_common_js_files + | 22 gypi_values.devtools_common_js_files + |
21 gypi_values.devtools_components_js_files + | 23 gypi_values.devtools_components_js_files + |
22 gypi_values.devtools_host_js_files + | 24 gypi_values.devtools_host_js_files + |
23 gypi_values.devtools_main_js_files + | 25 gypi_values.devtools_main_js_files + |
26 gypi_values.devtools_screencast_js_files + | |
24 gypi_values.devtools_sdk_js_files + | 27 gypi_values.devtools_sdk_js_files + |
25 gypi_values.devtools_screencast_js_files + | |
26 gypi_values.devtools_toolbox_js_files + | 28 gypi_values.devtools_toolbox_js_files + |
27 gypi_values.devtools_toolbox_bootstrap_js_files + | 29 gypi_values.devtools_toolbox_bootstrap_js_files + |
28 gypi_values.devtools_ui_js_files + | 30 gypi_values.devtools_ui_js_files + |
29 gypi_values.devtools_workspace_js_files | 31 gypi_values.devtools_workspace_js_files |
30 | 32 |
31 devtools_extensions_js_files = gypi_values.devtools_extensions_js_files - | 33 devtools_extensions_js_files = gypi_values.devtools_extensions_js_files - |
32 [ "<@(devtools_extension_api_files)" ] + | 34 [ "<@(devtools_extension_api_files)" ] + |
33 gypi_values.devtools_extension_api_files | 35 gypi_values.devtools_extension_api_files |
34 | 36 |
35 devtools_modules_js_files = | 37 devtools_modules_js_files = |
(...skipping 17 matching lines...) Expand all Loading... | |
53 gypi_values.devtools_timeline_js_files | 55 gypi_values.devtools_timeline_js_files |
54 | 56 |
55 all_devtools_files = | 57 all_devtools_files = |
56 gypi_values.devtools_cm_css_files + | 58 gypi_values.devtools_cm_css_files + |
57 gypi_values.devtools_cm_js_files + | 59 gypi_values.devtools_cm_js_files + |
58 devtools_core_files + | 60 devtools_core_files + |
59 gypi_values.devtools_module_json_files + | 61 gypi_values.devtools_module_json_files + |
60 devtools_modules_js_files + | 62 devtools_modules_js_files + |
61 gypi_values.devtools_uglify_files | 63 gypi_values.devtools_uglify_files |
62 | 64 |
65 # FIXME: Fix the generate_devtools_grd.py script to accept trailing slashes. | |
66 resources_out_dir_no_slash = "$root_out_dir/resources/inspector" | |
67 resources_out_dir = resources_out_dir_no_slash + "/" | |
68 | |
69 generated_scripts = [ | |
70 resources_out_dir + "InspectorBackendCommands.js", | |
71 resources_out_dir + "SupportedCSSProperties.js", | |
72 ] | |
73 | |
63 #------------------------------------------------------------------------------- | 74 #------------------------------------------------------------------------------- |
64 | 75 |
65 visibility = [ "//third_party/WebKit/*" ] | 76 visibility = [ "//third_party/WebKit/*" ] |
66 | 77 |
67 # Probably need to parameterize this. If we set it to true, there will be some | |
68 # further work in the scripts below. | |
69 debug_devtools = false | |
70 | |
71 group("devtools_frontend_resources") { | 78 group("devtools_frontend_resources") { |
72 deps = [ | 79 deps = [ |
73 ":copy_inspector_images", | |
74 ":devtools_html", | 80 ":devtools_html", |
75 ":toolbox_html", | 81 ":toolbox_html", |
82 ":copy_inspector_images", | |
83 ":copy_standalone_css", | |
84 ":devtools_extension_api", | |
76 ":frontend_protocol_sources", | 85 ":frontend_protocol_sources", |
77 ":supported_css_properties", | 86 ":supported_css_properties", |
78 ":build_applications", | 87 ":build_applications", |
79 ] | 88 ] |
80 | 89 |
81 if (!debug_devtools) { | 90 if (!debug_devtools) { |
91 # This overwrites application-specific core CSS (devtools.css), | |
92 # and thus should be guarded out in Debug builds. | |
82 deps += [ | 93 deps += [ |
83 ":copy_standalone_css", | |
84 ":concatenated_devtools_css", | 94 ":concatenated_devtools_css", |
85 ":concatenated_toolbox_css", | 95 ":concatenated_toolbox_css", |
86 ] | 96 ] |
87 } | 97 } |
88 } | 98 } |
89 | 99 |
90 copy("copy_inspector_images") { | 100 copy("copy_inspector_images") { |
91 sources = gypi_values.devtools_image_files | 101 sources = gypi_values.devtools_image_files |
92 outputs = [ "$root_out_dir/resources/inspector/Images/{{source_file_part}}" ] | 102 outputs = [ resources_out_dir + "Images/{{source_file_part}}" ] |
93 } | 103 } |
94 | 104 |
95 # TODO(GYP) need debug_devtools support (this runs somewhat differently). | |
96 action("generate_devtools_grd") { | 105 action("generate_devtools_grd") { |
97 script = "scripts/generate_devtools_grd.py" | 106 script = "scripts/generate_devtools_grd.py" |
98 | 107 |
99 input_pages = [ | 108 deps = [ ":devtools_frontend_resources" ] |
100 "$root_out_dir/resources/inspector/devtools.css", | 109 |
101 "$root_out_dir/resources/inspector/devtools.html", | 110 if (debug_devtools) { |
102 "$root_out_dir/resources/inspector/devtools.js", | 111 # Debug: all files are picked as-is. |
103 "$root_out_dir/resources/inspector/toolbox.css", | 112 input_pages = all_devtools_files + generated_scripts + [ |
104 "$root_out_dir/resources/inspector/toolbox.html", | 113 resources_out_dir + "devtools.html", |
105 "$root_out_dir/resources/inspector/toolbox.js", | 114 resources_out_dir + "toolbox.html", |
106 "$root_out_dir/resources/inspector/audits_module.js", | 115 ] |
107 "$root_out_dir/resources/inspector/console_module.js", | 116 } else { |
108 "$root_out_dir/resources/inspector/devices_module.js", | 117 # Release: pick compiled files and lazy-loaded CSS. |
109 "$root_out_dir/resources/inspector/documentation_module.js", | 118 input_pages = [ |
110 "$root_out_dir/resources/inspector/elements_module.js", | 119 resources_out_dir + "devtools.css", |
111 "$root_out_dir/resources/inspector/extensions_module.js", | 120 resources_out_dir + "devtools.html", |
112 "$root_out_dir/resources/inspector/heap_snapshot_worker_module.js", | 121 resources_out_dir + "devtools.js", |
113 "$root_out_dir/resources/inspector/layers_module.js", | 122 resources_out_dir + "toolbox.css", |
114 "$root_out_dir/resources/inspector/network_module.js", | 123 resources_out_dir + "toolbox.html", |
115 "$root_out_dir/resources/inspector/profiler_module.js", | 124 resources_out_dir + "toolbox.js", |
116 "$root_out_dir/resources/inspector/promises_module.js", | 125 resources_out_dir + "audits_module.js", |
117 "$root_out_dir/resources/inspector/resources_module.js", | 126 resources_out_dir + "console_module.js", |
118 "$root_out_dir/resources/inspector/script_formatter_worker_module.js", | 127 resources_out_dir + "devices_module.js", |
119 "$root_out_dir/resources/inspector/settings_module.js", | 128 resources_out_dir + "documentation_module.js", |
120 "$root_out_dir/resources/inspector/source_frame_module.js", | 129 resources_out_dir + "elements_module.js", |
121 "$root_out_dir/resources/inspector/sources_module.js", | 130 resources_out_dir + "extensions_module.js", |
122 "$root_out_dir/resources/inspector/temp_storage_shared_worker_module.js", | 131 resources_out_dir + "heap_snapshot_worker_module.js", |
123 "$root_out_dir/resources/inspector/timeline_module.js", | 132 resources_out_dir + "layers_module.js", |
124 "$root_out_dir/resources/inspector/devtools_extension_api.js", | 133 resources_out_dir + "network_module.js", |
125 ] + gypi_values.devtools_standalone_files + gypi_values.devtools_cm_css_files | 134 resources_out_dir + "profiler_module.js", |
135 resources_out_dir + "promises_module.js", | |
136 resources_out_dir + "resources_module.js", | |
137 resources_out_dir + "script_formatter_worker_module.js", | |
138 resources_out_dir + "settings_module.js", | |
139 resources_out_dir + "source_frame_module.js", | |
140 resources_out_dir + "sources_module.js", | |
141 resources_out_dir + "temp_storage_shared_worker_module.js", | |
142 resources_out_dir + "timeline_module.js", | |
143 resources_out_dir + "devtools_extension_api.js", | |
144 ] | |
145 input_pages += gypi_values.devtools_standalone_files + | |
146 gypi_values.devtools_cm_css_files | |
147 } | |
126 | 148 |
127 images = gypi_values.devtools_image_files | 149 images = gypi_values.devtools_image_files |
128 images_path = "front_end/Images" | 150 images_path = "front_end/Images" |
129 | 151 |
130 inputs = input_pages + images | 152 inputs = input_pages + images |
131 | 153 |
132 outfile = "$root_gen_dir/devtools/devtools_resources.grd" | 154 outfile = "$root_gen_dir/devtools/devtools_resources.grd" |
133 outputs = [ outfile ] | 155 outputs = [ outfile ] |
134 | 156 |
135 relative_path_dirs = [ | 157 relative_path_dirs = [ |
136 "$root_out_dir/resources/inspector", | 158 resources_out_dir_no_slash, |
137 "front_end", | 159 "front_end", |
138 ] | 160 ] |
139 | 161 |
140 args = rebase_path(input_pages, root_build_dir) + [ | 162 args = rebase_path(input_pages, root_build_dir) + [ |
141 "--relative_path_dirs" ] + | 163 "--relative_path_dirs" ] + |
142 rebase_path(relative_path_dirs, root_build_dir) + [ | 164 rebase_path(relative_path_dirs, root_build_dir) + [ |
143 "--images", rebase_path(images_path, root_build_dir), | 165 "--images", rebase_path(images_path, root_build_dir), |
144 "--output", rebase_path(outfile, root_build_dir), | 166 "--output", rebase_path(outfile, root_build_dir), |
145 ] | 167 ] |
146 | |
147 deps = [ | |
148 ":devtools_html", | |
149 ":toolbox_html", | |
150 ":devtools_extension_api", | |
151 ":devtools_frontend_resources", | |
152 ] | |
153 } | 168 } |
154 | 169 |
155 template("generate_app_html") { | 170 template("generate_app_html") { |
156 assert(defined(invoker.app_name), target_name) | 171 assert(defined(invoker.app_name), target_name) |
172 app_name = invoker.app_name | |
157 | 173 |
158 action(target_name) { | 174 action(target_name) { |
159 script = "scripts/generate_devtools_html.py" | 175 script = "scripts/generate_devtools_html.py" |
160 | 176 |
161 inputs = [ "front_end/" + invoker.app_name + ".html"] | 177 inputs = [ "front_end/" + app_name + ".html"] |
162 outputs = [ | 178 outputs = [ resources_out_dir + app_name + ".html" ] |
163 "$root_out_dir/resources/inspector/" + invoker.app_name + ".html" | |
164 ] | |
165 | 179 |
166 args = rebase_path(inputs, root_build_dir) + | 180 args = rebase_path(inputs, root_build_dir) + |
167 rebase_path(outputs, root_build_dir) | 181 rebase_path(outputs, root_build_dir) |
168 | 182 |
169 if (debug_devtools) { | 183 if (debug_devtools) { |
170 args += [ "1" ] | 184 args += [ "1" ] |
171 } else { | 185 } else { |
172 args += [ "0" ] | 186 args += [ "0" ] |
173 } | 187 } |
174 } | 188 } |
175 } | 189 } |
176 | 190 |
177 generate_app_html("devtools_html") { | 191 generate_app_html("devtools_html") { |
178 app_name = "devtools" | 192 app_name = "devtools" |
179 } | 193 } |
180 | 194 |
181 generate_app_html("toolbox_html") { | 195 generate_app_html("toolbox_html") { |
182 app_name = "toolbox" | 196 app_name = "toolbox" |
183 } | 197 } |
184 | 198 |
185 action("devtools_extension_api") { | 199 action("devtools_extension_api") { |
186 script = "scripts/generate_devtools_extension_api.py" | 200 script = "scripts/generate_devtools_extension_api.py" |
187 | 201 |
188 inputs = gypi_values.devtools_extension_api_files | 202 inputs = gypi_values.devtools_extension_api_files |
189 outputs = [ "$root_out_dir/resources/inspector/devtools_extension_api.js" ] | 203 outputs = [ resources_out_dir + "devtools_extension_api.js" ] |
190 | 204 |
191 args = rebase_path(outputs, root_build_dir) + | 205 args = rebase_path(outputs, root_build_dir) + |
192 rebase_path(gypi_values.devtools_extension_api_files, root_build_dir) | 206 rebase_path(gypi_values.devtools_extension_api_files, root_build_dir) |
193 } | 207 } |
194 | 208 |
195 action("supported_css_properties") { | 209 action("supported_css_properties") { |
196 script = "scripts/generate_supported_css.py" | 210 script = "scripts/generate_supported_css.py" |
197 | 211 |
198 inputs = [ | 212 inputs = [ "../core/css/CSSProperties.in" ] |
199 "../core/css/CSSProperties.in", | |
200 ] | |
201 | 213 |
202 outputs = [ | 214 outputs = [ resources_out_dir + "SupportedCSSProperties.js" ] |
203 "$root_out_dir/resources/inspector/SupportedCSSProperties.js" | |
204 ] | |
205 | 215 |
206 args = rebase_path(inputs, root_build_dir) + | 216 args = rebase_path(inputs, root_build_dir) + |
207 rebase_path(outputs, root_build_dir) | 217 rebase_path(outputs, root_build_dir) |
208 } | 218 } |
209 | 219 |
210 action("frontend_protocol_sources") { | 220 action("frontend_protocol_sources") { |
211 script = "scripts/CodeGeneratorFrontend.py" | 221 script = "scripts/CodeGeneratorFrontend.py" |
212 | 222 |
213 inputs = [ "protocol.json" ] | 223 inputs = [ "protocol.json" ] |
214 outputs = [ "$root_out_dir/resources/inspector/InspectorBackendCommands.js" ] | 224 outputs = [ resources_out_dir + "InspectorBackendCommands.js" ] |
215 | 225 |
216 args = rebase_path(inputs, root_build_dir) + [ | 226 args = rebase_path(inputs, root_build_dir) + [ |
217 "--output_js_dir", | 227 "--output_js_dir", |
218 rebase_path("$root_out_dir/resources/inspector", root_build_dir), | 228 rebase_path(resources_out_dir, root_build_dir), |
219 ] | 229 ] |
220 } | 230 } |
221 | 231 |
222 action("build_applications") { | 232 group("build_applications") { |
223 script = "scripts/build_applications.py" | 233 deps = [] |
224 helper_scripts = [ | 234 |
225 "scripts/modular_build.py", | 235 if (!debug_devtools) { |
226 "scripts/concatenate_application_code.py", | 236 # Release: concatenate application code. This overwrites |
227 ] | 237 # application-specific scripts (devtools.js), and thus should be guarded. |
228 | 238 action("build_applications_release") { |
dgozman
2014/10/01 13:28:24
Shouldn't you add "build_applications_release" to
apavlov
2014/10/01 13:55:19
Done.
| |
229 generated_inputs = [ | 239 script = "scripts/build_applications.py" |
230 "$root_out_dir/resources/inspector/InspectorBackendCommands.js", | 240 helper_scripts = [ |
231 "$root_out_dir/resources/inspector/SupportedCSSProperties.js", | 241 "scripts/modular_build.py", |
232 ] | 242 "scripts/concatenate_application_code.py", |
233 | 243 ] |
234 inputs = helper_scripts + all_devtools_files + generated_inputs | 244 |
235 | 245 inputs = helper_scripts + all_devtools_files + generated_scripts |
236 output_path = "$root_out_dir/resources/inspector/" | 246 |
237 outputs = [ | 247 outputs = [ |
238 output_path + "devtools.js", | 248 resources_out_dir + "devtools.js", |
239 output_path + "toolbox.js", | 249 resources_out_dir + "toolbox.js", |
240 output_path + "audits_module.js", | 250 resources_out_dir + "audits_module.js", |
241 output_path + "console_module.js", | 251 resources_out_dir + "console_module.js", |
242 output_path + "devices_module.js", | 252 resources_out_dir + "devices_module.js", |
243 output_path + "documentation_module.js", | 253 resources_out_dir + "documentation_module.js", |
244 output_path + "elements_module.js", | 254 resources_out_dir + "elements_module.js", |
245 output_path + "extensions_module.js", | 255 resources_out_dir + "extensions_module.js", |
246 output_path + "heap_snapshot_worker_module.js", | 256 resources_out_dir + "heap_snapshot_worker_module.js", |
247 output_path + "layers_module.js", | 257 resources_out_dir + "layers_module.js", |
248 output_path + "network_module.js", | 258 resources_out_dir + "network_module.js", |
249 output_path + "profiler_module.js", | 259 resources_out_dir + "profiler_module.js", |
250 output_path + "promises_module.js", | 260 resources_out_dir + "promises_module.js", |
251 output_path + "resources_module.js", | 261 resources_out_dir + "resources_module.js", |
252 output_path + "script_formatter_worker_module.js", | 262 resources_out_dir + "script_formatter_worker_module.js", |
253 output_path + "settings_module.js", | 263 resources_out_dir + "settings_module.js", |
254 output_path + "source_frame_module.js", | 264 resources_out_dir + "source_frame_module.js", |
255 output_path + "sources_module.js", | 265 resources_out_dir + "sources_module.js", |
256 output_path + "temp_storage_shared_worker_module.js", | 266 resources_out_dir + "temp_storage_shared_worker_module.js", |
257 output_path + "timeline_module.js", | 267 resources_out_dir + "timeline_module.js", |
258 ] | 268 ] |
259 | 269 |
260 if (debug_devtools) { | 270 args = [ |
261 debug_flag = "1" | 271 "devtools", "toolbox", |
272 "--input_path", rebase_path("front_end", root_build_dir), | |
273 "--output_path", rebase_path(resources_out_dir, root_build_dir), | |
274 "--debug", "0" | |
275 ] | |
276 | |
277 deps += [ | |
278 ":supported_css_properties", | |
279 ":frontend_protocol_sources", | |
280 ] | |
281 } | |
262 } else { | 282 } else { |
263 debug_flag = "0" | |
264 } | |
265 | |
266 app_names = [ | |
267 "devtools", | |
268 "toolbox" | |
269 ] | |
270 | |
271 args = app_names + [ | |
272 "--input_path", rebase_path("front_end", root_build_dir), | |
273 "--output_path", rebase_path(output_path, root_build_dir), | |
274 "--debug", debug_flag | |
275 ] | |
276 | |
277 deps = [] | |
278 | |
279 if (!debug_devtools) { | |
280 deps += [ | 283 deps += [ |
281 ":devtools_html", | 284 ":copy_debug_modules" |
282 ":toolbox_html", | |
283 ":supported_css_properties", | |
284 ":frontend_protocol_sources", | |
285 ] | 285 ] |
286 } | 286 } |
287 } | 287 } |
288 | 288 |
289 template("concatenate_css") { | 289 copy("copy_standalone_css") { |
290 assert(defined(invoker.app_name), target_name) | 290 sources = gypi_values.devtools_standalone_files |
291 | 291 outputs = [ resources_out_dir + "{{source_file_part}}" ] |
292 action(target_name) { | 292 |
293 script = "scripts/concatenate_css_files.py" | 293 copy("copy_codemirror_css") { |
294 | 294 sources = gypi_values.devtools_cm_css_files |
295 input_stylesheet = "front_end/" + invoker.app_name + ".css" | 295 outputs = [ resources_out_dir + "cm/{{source_file_part}}" ] |
296 inputs = [ input_stylesheet ] + devtools_core_base_files | 296 } |
297 | 297 |
298 outputs = [ | 298 deps = [ ":copy_codemirror_css" ] |
299 "$root_out_dir/resources/inspector/" + invoker.app_name + ".css" | 299 } |
300 | |
301 if (debug_devtools) { | |
302 # Debug: copy front-end into resources_out_dir as-is. | |
303 group("copy_debug_modules") { | |
304 deps = [ | |
305 ":copy_audits_module", | |
306 ":copy_bindings_module", | |
307 ":copy_common_module", | |
308 ":copy_components_module", | |
309 ":copy_console_module", | |
310 ":copy_devices_module", | |
311 ":copy_documentation_module", | |
312 ":copy_elements_module", | |
313 ":copy_extensions_module", | |
314 ":copy_host_module", | |
315 ":copy_layers_module", | |
316 ":copy_main_module", | |
317 ":copy_network_module", | |
318 ":copy_profiler_module", | |
319 ":copy_promises_module", | |
320 ":copy_resources_module", | |
321 ":copy_screencast_module", | |
322 ":copy_sdk_module", | |
323 ":copy_settings_module", | |
324 ":copy_source_frame_module", | |
325 ":copy_sources_module", | |
326 ":copy_timeline_module", | |
327 ":copy_toolbox_module", | |
328 ":copy_toolbox_bootstrap_module", | |
329 ":copy_ui_module", | |
330 ":copy_workspace_module", | |
300 ] | 331 ] |
301 | 332 |
302 args = [ rebase_path(input_stylesheet, root_build_dir) ] + | 333 copy("copy_runtime_core") { |
303 rebase_path(outputs, root_build_dir) | 334 sources = devtools_core_base_files - |
304 } | 335 gypi_values.devtools_standalone_files |
305 } | 336 outputs = [ resources_out_dir + "/{{source_file_part}}" ] |
306 | 337 } |
307 concatenate_css("concatenated_devtools_css") { | 338 deps += [ ":copy_runtime_core" ] |
308 app_name = "devtools" | 339 } |
309 } | 340 |
310 | 341 # Copies module contents into resources_out_dir in debug_devtools=1 builds. |
311 concatenate_css("concatenated_toolbox_css") { | 342 # module_name: (String) The JS module name to process. |
312 app_name = "toolbox" | 343 # imported_files: (List of strings) The list of files the input depends on. |
313 } | 344 template("copy_debug_module") { |
314 | 345 assert(defined(invoker.module_name), target_name) |
315 copy("copy_codemirror_css") { | 346 assert(defined(invoker.imported_files), target_name) |
316 sources = gypi_values.devtools_cm_css_files | 347 |
317 outputs = [ "$root_out_dir/resources/inspector/cm/{{source_file_part}}" ] | 348 imported_files = invoker.imported_files |
318 } | 349 module_name = invoker.module_name |
319 | 350 module_json = "front_end/" + module_name + "/module.json" |
320 copy("copy_standalone_css") { | 351 |
321 sources = gypi_values.devtools_standalone_files | 352 copy(target_name) { |
322 outputs = [ "$root_out_dir/resources/inspector/{{source_file_part}}" ] | 353 sources = [ module_json ] + imported_files |
323 | 354 outputs = [ resources_out_dir + module_name + "/{{source_file_part}}" ] |
324 deps = [ ":copy_codemirror_css" ] | 355 } |
325 } | 356 } |
357 | |
358 copy_debug_module("copy_audits_module") { | |
359 module_name = "audits" | |
360 imported_files = gypi_values.devtools_audits_js_files | |
361 } | |
362 | |
363 copy_debug_module("copy_bindings_module") { | |
364 module_name = "bindings" | |
365 imported_files = gypi_values.devtools_bindings_js_files | |
366 } | |
367 | |
368 copy_debug_module("copy_common_module") { | |
369 module_name = "common" | |
370 imported_files = gypi_values.devtools_common_js_files | |
371 } | |
372 | |
373 copy_debug_module("copy_components_module") { | |
374 module_name = "components" | |
375 imported_files = gypi_values.devtools_components_js_files | |
376 } | |
377 | |
378 copy_debug_module("copy_console_module") { | |
379 module_name = "console" | |
380 imported_files = gypi_values.devtools_console_js_files | |
381 } | |
382 | |
383 copy_debug_module("copy_devices_module") { | |
384 module_name = "devices" | |
385 imported_files = gypi_values.devtools_devices_js_files | |
386 } | |
387 | |
388 copy_debug_module("copy_documentation_module") { | |
389 module_name = "documentation" | |
390 imported_files = gypi_values.devtools_documentation_js_files | |
391 } | |
392 | |
393 copy_debug_module("copy_elements_module") { | |
394 module_name = "elements" | |
395 imported_files = gypi_values.devtools_elements_js_files | |
396 } | |
397 | |
398 copy_debug_module("copy_extensions_module") { | |
399 module_name = "extensions" | |
400 imported_files = devtools_extensions_js_files | |
401 } | |
402 | |
403 copy_debug_module("copy_heap_snapshot_worker_module") { | |
404 module_name = "heap_snapshot_worker" | |
405 imported_files = gypi_values.devtools_heap_snapshot_worker_js_files | |
406 } | |
407 | |
408 copy_debug_module("copy_host_module") { | |
409 module_name = "host" | |
410 imported_files = gypi_values.devtools_host_js_files | |
411 } | |
412 | |
413 copy_debug_module("copy_layers_module") { | |
414 module_name = "layers" | |
415 imported_files = gypi_values.devtools_layers_js_files | |
416 } | |
417 | |
418 copy_debug_module("copy_main_module") { | |
419 module_name = "main" | |
420 imported_files = gypi_values.devtools_main_js_files | |
421 } | |
422 | |
423 copy_debug_module("copy_network_module") { | |
424 module_name = "network" | |
425 imported_files = gypi_values.devtools_network_js_files | |
426 } | |
427 | |
428 copy_debug_module("copy_profiler_module") { | |
429 module_name = "profiler" | |
430 imported_files = gypi_values.devtools_profiler_js_files | |
431 } | |
432 | |
433 copy_debug_module("copy_promises_module") { | |
434 module_name = "promises" | |
435 imported_files = gypi_values.devtools_promises_js_files | |
436 } | |
437 | |
438 copy_debug_module("copy_resources_module") { | |
439 module_name = "resources" | |
440 imported_files = gypi_values.devtools_resources_js_files | |
441 } | |
442 | |
443 copy_debug_module("copy_screencast_module") { | |
444 module_name = "screencast" | |
445 imported_files = gypi_values.devtools_screencast_js_files | |
446 } | |
447 | |
448 group("copy_script_formatter_worker_module") { | |
449 copy_debug_module("copy_script_formatter_worker_module_base") { | |
450 module_name = "script_formatter_worker" | |
451 imported_files = gypi_values.devtools_uglify_files + | |
452 gypi_values.devtools_script_formatter_worker_js_files | |
453 } | |
454 | |
455 copy("copy_uglify_js_files") { | |
456 sources = gypi_values.devtools_uglify_files | |
457 outputs = [ resources_out_dir + "UglifyJS/{{source_file_part}}" ] | |
458 } | |
459 | |
460 deps = [ | |
461 ":copy_script_formatter_worker_module_base", | |
462 ":copy_uglify_js_files" | |
463 ] | |
464 } | |
465 | |
466 copy_debug_module("copy_sdk_module") { | |
467 module_name = "sdk" | |
468 imported_files = gypi_values.devtools_sdk_js_files | |
469 } | |
470 | |
471 copy_debug_module("copy_settings_module") { | |
472 module_name = "settings" | |
473 imported_files = gypi_values.devtools_settings_js_files | |
474 } | |
475 | |
476 copy_debug_module("copy_source_frame_module") { | |
477 module_name = "source_frame" | |
478 imported_files = gypi_values.devtools_source_frame_js_files | |
479 } | |
480 | |
481 copy_debug_module("copy_sources_module") { | |
482 module_name = "sources" | |
483 imported_files = gypi_values.devtools_sources_js_files | |
484 } | |
485 | |
486 copy_debug_module("copy_temp_storage_shared_worker_module") { | |
487 module_name = "temp_storage_shared_worker" | |
488 imported_files = gypi_values.devtools_temp_storage_shared_worker_js_files | |
489 } | |
490 | |
491 copy_debug_module("copy_timeline_module") { | |
492 module_name = "timeline" | |
493 imported_files = gypi_values.devtools_timeline_js_files | |
494 } | |
495 | |
496 copy_debug_module("copy_toolbox_module") { | |
497 module_name = "toolbox" | |
498 imported_files = gypi_values.devtools_toolbox_js_files | |
499 } | |
500 | |
501 copy_debug_module("copy_toolbox_bootstrap_module") { | |
502 module_name = "toolbox_bootstrap" | |
503 imported_files = gypi_values.devtools_toolbox_bootstrap_js_files | |
504 } | |
505 | |
506 copy_debug_module("copy_ui_module") { | |
507 module_name = "ui" | |
508 imported_files = gypi_values.devtools_ui_js_files | |
509 } | |
510 | |
511 copy_debug_module("copy_workspace_module") { | |
512 module_name = "workspace" | |
513 imported_files = gypi_values.devtools_workspace_js_files | |
514 } | |
515 } | |
516 | |
517 if (!debug_devtools) { | |
518 # Release: Concatenate application CSS. | |
519 template("concatenate_css") { | |
520 assert(defined(invoker.app_name), target_name) | |
521 app_name = invoker.app_name | |
522 | |
523 action(target_name) { | |
524 script = "scripts/concatenate_css_files.py" | |
525 | |
526 input_stylesheet = "front_end/" + app_name + ".css" | |
527 inputs = [ input_stylesheet ] + devtools_core_base_files | |
528 | |
529 outputs = [ resources_out_dir + app_name + ".css" ] | |
530 | |
531 args = [ rebase_path(input_stylesheet, root_build_dir) ] + | |
532 rebase_path(outputs, root_build_dir) | |
533 } | |
534 } | |
535 | |
536 concatenate_css("concatenated_devtools_css") { | |
537 app_name = "devtools" | |
538 } | |
539 | |
540 concatenate_css("concatenated_toolbox_css") { | |
541 app_name = "toolbox" | |
542 } | |
543 } | |
OLD | NEW |