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 # Instantiate grit. This will produce a script target to run grit, and a | 5 # Instantiate grit. This will produce a script target to run grit, and a |
6 # static library that compiles the .cc files. | 6 # static library that compiles the .cc files. |
7 # | 7 # |
8 # Parameters | 8 # Parameters |
9 # | 9 # |
10 # source (required) | 10 # source (required) |
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
438 } | 438 } |
439 } | 439 } |
440 | 440 |
441 # This is the thing that people actually link with, it must be named the | 441 # This is the thing that people actually link with, it must be named the |
442 # same as the argument the template was invoked with. | 442 # same as the argument the template was invoked with. |
443 source_set(target_name) { | 443 source_set(target_name) { |
444 # Since we generate a file, we need to be run before the targets that | 444 # Since we generate a file, we need to be run before the targets that |
445 # depend on us. | 445 # depend on us. |
446 sources = grit_outputs | 446 sources = grit_outputs |
447 | 447 |
448 # Deps set on the template invocation will go on the action that runs | 448 # Deps set on the template invocation will go on the grit script running |
449 # grit above rather than this library. This target needs to depend on the | 449 # target rather than this library. |
450 # action publicly so other scripts can take the outputs from the grit | 450 deps = [ |
451 # script as inputs. | |
452 public_deps = [ | |
453 ":$grit_custom_target", | 451 ":$grit_custom_target", |
454 ] | 452 ] |
455 public_configs = [ ":$grit_config" ] | 453 public_configs = [ ":$grit_config" ] |
456 | 454 |
457 if (defined(invoker.public_configs)) { | 455 if (defined(invoker.public_configs)) { |
458 public_configs += invoker.public_configs | 456 public_configs += invoker.public_configs |
459 } | 457 } |
460 | 458 |
461 if (defined(invoker.configs)) { | 459 if (defined(invoker.configs)) { |
462 configs += invoker.configs | 460 configs += invoker.configs |
463 } | 461 } |
464 | 462 |
465 if (defined(invoker.visibility)) { | 463 if (defined(invoker.visibility)) { |
466 visibility = invoker.visibility | 464 visibility = invoker.visibility |
467 } | 465 } |
468 output_name = grit_output_name | 466 output_name = grit_output_name |
469 } | 467 } |
470 } | 468 } |
OLD | NEW |