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 # Compile a protocol buffer. | 5 # Compile a protocol buffer. |
6 # | 6 # |
7 # Protobuf parameters: | 7 # Protobuf parameters: |
8 # | 8 # |
9 # proto_out_dir (optional) | 9 # proto_out_dir (optional) |
10 # Specifies the path suffix that output files are generated under. This | 10 # Specifies the path suffix that output files are generated under. This |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
141 ] | 141 ] |
142 | 142 |
143 deps = [ | 143 deps = [ |
144 protoc_label, | 144 protoc_label, |
145 ] | 145 ] |
146 | 146 |
147 # The deps may have steps that have to run before runnign protobuf. | 147 # The deps may have steps that have to run before runnign protobuf. |
148 if (defined(invoker.deps)) { | 148 if (defined(invoker.deps)) { |
149 deps += invoker.deps | 149 deps += invoker.deps |
150 } | 150 } |
151 | |
152 if (defined(invoker.json_converter)) { | |
153 args += [ | |
154 "--plugin=protoc-gen-json_converter=" + | |
155 rebase_path(invoker.json_converter, root_build_dir), | |
156 "--json_converter_out=output_dir=:$rel_out_dir", | |
dcheng
2016/06/14 04:27:39
Seems a bit weird to specify this here, maybe we c
wychen
2016/08/07 09:16:27
Moving all the logic to dom_distiller_js/BUILD.gn
| |
157 ] | |
158 outputs += [ "$out_dir/{{source_name_part}}_json_converter.h" ] | |
159 } | |
151 } | 160 } |
152 | 161 |
153 source_set(target_name) { | 162 source_set(target_name) { |
154 forward_variables_from(invoker, | 163 forward_variables_from(invoker, |
155 [ | 164 [ |
156 "visibility", | 165 "visibility", |
157 "defines", | 166 "defines", |
158 ]) | 167 ]) |
159 | 168 |
160 sources = get_target_outputs(":$action_name") | 169 sources = get_target_outputs(":$action_name") |
(...skipping 13 matching lines...) Expand all Loading... | |
174 ":$action_name", | 183 ":$action_name", |
175 ] | 184 ] |
176 | 185 |
177 # This will link any libraries in the deps (the use of invoker.deps in the | 186 # This will link any libraries in the deps (the use of invoker.deps in the |
178 # action won't link it). | 187 # action won't link it). |
179 if (defined(invoker.deps)) { | 188 if (defined(invoker.deps)) { |
180 deps += invoker.deps | 189 deps += invoker.deps |
181 } | 190 } |
182 } | 191 } |
183 } | 192 } |
OLD | NEW |