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("//third_party/WebKit/Source/core/core_idl_files.gni") | 5 import("//third_party/WebKit/Source/core/core_idl_files.gni") |
6 import("//third_party/WebKit/Source/modules/modules_idl_files.gni") | 6 import("//third_party/WebKit/Source/modules/modules_idl_files.gni") |
7 | 7 |
8 bindings_scripts_dir = get_path_info(".", "abspath") | 8 bindings_scripts_dir = get_path_info(".", "abspath") |
9 bindings_scripts_output_dir = "$root_gen_dir/blink/bindings/scripts" | 9 bindings_scripts_output_dir = "$root_gen_dir/blink/bindings/scripts" |
10 | 10 |
(...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
427 args += [ rebase_path(output_idl_file, root_build_dir) ] | 427 args += [ rebase_path(output_idl_file, root_build_dir) ] |
428 output_idl_files += [ output_idl_file ] | 428 output_idl_files += [ output_idl_file ] |
429 output_header_files += | 429 output_header_files += |
430 [ "$output_dir/${interface}${component}Constructors.h" ] | 430 [ "$output_dir/${interface}${component}Constructors.h" ] |
431 } | 431 } |
432 | 432 |
433 outputs = output_idl_files + output_header_files | 433 outputs = output_idl_files + output_header_files |
434 deps = invoker.deps | 434 deps = invoker.deps |
435 } | 435 } |
436 } | 436 } |
| 437 |
| 438 # Calls the generate_conditional_features script. |
| 439 # |
| 440 # Parameters: |
| 441 # sources = a list of source IDL files. |
| 442 # global_objects_file = a global objects file generated by compute_global_obje
cts |
| 443 # component = component to generate conditional feature bindings for ("Core" o
r "Modules") |
| 444 # output_dir = output directory to generate cpp file and header file. |
| 445 # deps = dependencies |
| 446 # |
| 447 template("generate_conditional_features") { |
| 448 action(target_name) { |
| 449 script = "//third_party/WebKit/Source/bindings/scripts/generate_conditional_
features.py" |
| 450 |
| 451 # Write the file list to a unique temp file to avoid blowing out the |
| 452 # command line length limit. |
| 453 idl_files_list = "$target_gen_dir/${target_name}_file_list.tmp" |
| 454 write_file(idl_files_list, rebase_path(invoker.sources, root_build_dir)) |
| 455 |
| 456 inputs = [ |
| 457 "//third_party/WebKit/Source/bindings/scripts/utilities.py", |
| 458 idl_files_list, |
| 459 invoker.global_objects_file, |
| 460 ] + invoker.sources |
| 461 |
| 462 args = [ |
| 463 "--output-directory", |
| 464 rebase_path(invoker.output_dir, root_build_dir), |
| 465 "--info-dir", |
| 466 "gen/blink/bindings", |
| 467 "--cache-dir", |
| 468 rebase_path(bindings_scripts_output_dir, root_build_dir), |
| 469 "--target-component", |
| 470 invoker.component, |
| 471 "--idl-files-list", |
| 472 rebase_path(idl_files_list, root_build_dir), |
| 473 "--global-objects-file", |
| 474 rebase_path(invoker.global_objects_file, root_build_dir), |
| 475 ] |
| 476 |
| 477 outputs = [ |
| 478 "${invoker.output_dir}/ConditionalFeaturesFor${invoker.component}.cpp", |
| 479 "${invoker.output_dir}/ConditionalFeaturesFor${invoker.component}.h", |
| 480 ] |
| 481 deps = invoker.deps |
| 482 } |
| 483 } |
OLD | NEW |