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

Unified Diff: tools/gn/secondary/tools/grit/grit_rule.gni

Issue 217273004: Pull GN @ r262225 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/gn/secondary/testing/gtest/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/secondary/tools/grit/grit_rule.gni
diff --git a/tools/gn/secondary/tools/grit/grit_rule.gni b/tools/gn/secondary/tools/grit/grit_rule.gni
index d658cbc5ae2df3c063da1eafe9c8bff90510de7b..f14a17588a8fab0552db85bedd2e67037e040ef4 100644
--- a/tools/gn/secondary/tools/grit/grit_rule.gni
+++ b/tools/gn/secondary/tools/grit/grit_rule.gni
@@ -55,6 +55,9 @@ template("grit") {
grit_config = target_name + "_grit_config"
config(grit_config) {
include_dirs = [ target_gen_dir ]
+
+ # Only our generated static library can depend on this.
+ visibility = ":" + target_name
}
grit_custom_target = target_name + "_grit"
@@ -70,7 +73,8 @@ template("grit") {
"-o", output_dir,
] + grit_flags
- # Inherit deps from template invocation if any.
+ # Only our generated static library can depend on this.
+ visibility = ":" + target_name
}
# This is the thing that people actually link with, it must be named the
@@ -86,5 +90,9 @@ template("grit") {
deps = []
deps = [ ":$grit_custom_target" ]
direct_dependent_configs = [ ":$grit_config" ]
+
+ if (defined(invoker.visibility)) {
+ visibility = invoker.visibility
+ }
}
}
« no previous file with comments | « tools/gn/secondary/testing/gtest/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698