OLD | NEW |
---|---|
(Empty) | |
1 # Copyright 2017 The Chromium Authors. All rights reserved. | |
2 # Use of this source code is governed by a BSD-style license that can be | |
3 # found in the LICENSE file. | |
4 | |
Nico
2017/02/06 22:35:10
add comment that explains what this is and how to
Evan Stade
2017/02/07 17:28:53
Done.
| |
5 template("aggregate_vector_icons") { | |
6 assert(defined(invoker.icons), | |
7 "Need icons in $target_name listing the icon files.") | |
8 assert( | |
9 defined(invoker.icon_directory), | |
10 "Need icon_directory in $target_name where the icons and templates live.") | |
11 | |
12 action(target_name) { | |
13 visibility = [ ":*" ] | |
14 | |
15 script = "//ui/gfx/vector_icons/aggregate_vector_icons.py" | |
16 | |
17 output_cc = "$target_gen_dir/vector_icons.cc" | |
18 output_h = "$target_gen_dir/vector_icons.h" | |
19 | |
20 templates = [ | |
21 "vector_icons.cc.template", | |
22 "vector_icons.h.template", | |
23 ] | |
24 inputs = rebase_path(templates + invoker.icons, ".", invoker.icon_directory) | |
25 | |
26 outputs = [ | |
27 output_cc, | |
28 output_h, | |
29 ] | |
30 | |
31 response_file_contents = | |
32 rebase_path(invoker.icons, root_build_dir, invoker.icon_directory) | |
33 | |
34 args = [ | |
35 "--working_directory=" + rebase_path(invoker.icon_directory), | |
36 "--file_list={{response_file_name}}", | |
37 "--output_cc=" + rebase_path(output_cc, root_build_dir), | |
38 "--output_h=" + rebase_path(output_h, root_build_dir), | |
39 ] | |
40 } | |
41 } | |
OLD | NEW |