Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: third_party/protobuf/proto_library.gni

Issue 365793002: Add lots of GN targets (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « third_party/mt19937ar/BUILD.gn ('k') | ui/accessibility/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_in_dir (optional) 9 # proto_in_dir (optional)
10 # The path to the directory containing the .proto files. If left out, it 10 # The path to the directory containing the .proto files. If left out, it
(...skipping 12 matching lines...) Expand all
23 # 'cc_generator_options' variable with the value: 23 # 'cc_generator_options' variable with the value:
24 # 'dllexport_decl=FOO_EXPORT:' (note trailing colon). 24 # 'dllexport_decl=FOO_EXPORT:' (note trailing colon).
25 # 25 #
26 # It is likely you also need to #include a file for the above EXPORT 26 # It is likely you also need to #include a file for the above EXPORT
27 # macro to work. See cc_include. 27 # macro to work. See cc_include.
28 # 28 #
29 # cc_include (optional) 29 # cc_include (optional)
30 # String listing an extra include that should be passed. 30 # String listing an extra include that should be passed.
31 # Example: cc_include = "foo/bar.h" 31 # Example: cc_include = "foo/bar.h"
32 # 32 #
33 # deps (optional)
34 # Additional dependencies.
35 #
33 # Parameters for compiling the generated code: 36 # Parameters for compiling the generated code:
34 # 37 #
35 # defines (optional) 38 # defines (optional)
36 # Defines to supply to the source set that compiles the generated source 39 # Defines to supply to the source set that compiles the generated source
37 # code. 40 # code.
38 # 41 #
39 # extra_configs (optional) 42 # extra_configs (optional)
40 # A list of config labels that will be appended to the configs applying 43 # A list of config labels that will be appended to the configs applying
41 # to the source set. 44 # to the source set.
42 # 45 #
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 cc_generator_options = invoker.cc_generator_options 121 cc_generator_options = invoker.cc_generator_options
119 } else { 122 } else {
120 cc_generator_options = "" 123 cc_generator_options = ""
121 } 124 }
122 args += [ 125 args += [
123 "--cpp_out", cc_generator_options + rebase_path(cc_dir, root_build_dir), 126 "--cpp_out", cc_generator_options + rebase_path(cc_dir, root_build_dir),
124 "--python_out", rebase_path(py_dir, root_build_dir), 127 "--python_out", rebase_path(py_dir, root_build_dir),
125 ] 128 ]
126 129
127 deps = [ protoc_label ] 130 deps = [ protoc_label ]
131
132 if (defined(invoker.deps)) {
133 deps += invoker.deps
134 }
128 } 135 }
129 136
130 source_set(target_name) { 137 source_set(target_name) {
131 if (defined(invoker.visibility)) { 138 if (defined(invoker.visibility)) {
132 visibility = invoker.visibility 139 visibility = invoker.visibility
133 } 140 }
134 141
135 sources = get_target_outputs(":$action_name") 142 sources = get_target_outputs(":$action_name")
136 143
137 if (defined(invoker.defines)) { 144 if (defined(invoker.defines)) {
138 defines = invoker.defines 145 defines = invoker.defines
139 } 146 }
140 if (defined(invoker.extra_configs)) { 147 if (defined(invoker.extra_configs)) {
141 configs += invoker.extra_configs 148 configs += invoker.extra_configs
142 } 149 }
143 150
144 direct_dependent_configs = [ "//third_party/protobuf:using_proto" ] 151 direct_dependent_configs = [ "//third_party/protobuf:using_proto" ]
145 152
146 deps = [ 153 deps = [
147 ":$action_name", 154 ":$action_name",
148 "//third_party/protobuf:protobuf_lite", 155 "//third_party/protobuf:protobuf_lite",
149 ] 156 ]
150 157
151 # The generated headers reference headers within protobuf_lite, so 158 # The generated headers reference headers within protobuf_lite, so
152 # dependencies must be able to find those headers too. 159 # dependencies must be able to find those headers too.
153 forward_dependent_configs_from = [ "//third_party/protobuf:protobuf_lite" ] 160 forward_dependent_configs_from = [ "//third_party/protobuf:protobuf_lite" ]
154 } 161 }
155 } 162 }
OLDNEW
« no previous file with comments | « third_party/mt19937ar/BUILD.gn ('k') | ui/accessibility/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698