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

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

Issue 544423002: Convert GN visibility variables to lists. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge Created 6 years, 3 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
« no previous file with comments | « third_party/protobuf/BUILD.gn ('k') | third_party/yasm/yasm_assemble.gni » ('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_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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 # "foo.proto", 48 # "foo.proto",
49 # ] 49 # ]
50 # } 50 # }
51 51
52 template("proto_library") { 52 template("proto_library") {
53 assert(defined(invoker.sources), "Need sources for proto_library") 53 assert(defined(invoker.sources), "Need sources for proto_library")
54 54
55 action_name = "${target_name}_gen" 55 action_name = "${target_name}_gen"
56 source_set_name = target_name 56 source_set_name = target_name
57 action_foreach(action_name) { 57 action_foreach(action_name) {
58 visibility = ":$source_set_name" 58 visibility = [ ":$source_set_name" ]
59 59
60 script = "//tools/protoc_wrapper/protoc_wrapper.py" 60 script = "//tools/protoc_wrapper/protoc_wrapper.py"
61 61
62 sources = invoker.sources 62 sources = invoker.sources
63 63
64 # Compute the output directory, both relative to the source root (for 64 # Compute the output directory, both relative to the source root (for
65 # declaring "outputs") and relative to the build dir (for passing to the 65 # declaring "outputs") and relative to the build dir (for passing to the
66 # script). 66 # script).
67 if (defined(invoker.proto_out_dir)) { 67 if (defined(invoker.proto_out_dir)) {
68 # Put the results in the specified dir in the gen tree. 68 # Put the results in the specified dir in the gen tree.
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 deps = [ 145 deps = [
146 ":$action_name", 146 ":$action_name",
147 "//third_party/protobuf:protobuf_lite", 147 "//third_party/protobuf:protobuf_lite",
148 ] 148 ]
149 149
150 # The generated headers reference headers within protobuf_lite, so 150 # The generated headers reference headers within protobuf_lite, so
151 # dependencies must be able to find those headers too. 151 # dependencies must be able to find those headers too.
152 forward_dependent_configs_from = [ "//third_party/protobuf:protobuf_lite" ] 152 forward_dependent_configs_from = [ "//third_party/protobuf:protobuf_lite" ]
153 } 153 }
154 } 154 }
OLDNEW
« no previous file with comments | « third_party/protobuf/BUILD.gn ('k') | third_party/yasm/yasm_assemble.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698