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

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

Issue 1108173002: Roll //build, //native_client, and a few more targets of opportunity. Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Test fix Created 5 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 | « build/secondary/third_party/sfntly/BUILD.gn ('k') | build/toolchain/gcc_toolchain.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/secondary/tools/grit/grit_rule.gni
diff --git a/build/secondary/tools/grit/grit_rule.gni b/build/secondary/tools/grit/grit_rule.gni
index 5d3b1e44357ed5a2f6b4fa91e48587c804b10439..09a04c1eb33ae22ecd62541a0e2b36383ca692cb 100644
--- a/build/secondary/tools/grit/grit_rule.gni
+++ b/build/secondary/tools/grit/grit_rule.gni
@@ -146,7 +146,7 @@ if (use_ash) {
if (use_nss_certs) {
grit_defines += [
"-D",
- "use_nss",
+ "use_nss_certs",
]
}
@@ -204,6 +204,12 @@ if (enable_extensions) {
"enable_extensions",
]
}
+if (enable_media_router) {
+ grit_defines += [
+ "-D",
+ "enable_media_router",
+ ]
+}
if (enable_plugins) {
grit_defines += [
"-D",
@@ -299,11 +305,14 @@ template("grit") {
assert(defined(invoker.source),
"\"source\" must be defined for the grit template $target_name")
+ grit_inputs = [ invoker.source ]
+
if (defined(invoker.resource_ids)) {
resource_ids = invoker.resource_ids
} else {
resource_ids = grit_resource_id_file
}
+ grit_inputs += [ resource_ids ] # Script depends on ID file.
if (defined(invoker.output_dir)) {
output_dir = invoker.output_dir
@@ -331,8 +340,6 @@ template("grit") {
grit_flags = [] # These are optional so default to empty list.
}
- grit_inputs = [ invoker.source ]
-
assert_files_flags = []
# We want to make sure the declared outputs actually match what Grit is
@@ -371,20 +378,8 @@ template("grit") {
script = "//tools/grit/grit.py"
inputs = grit_inputs
- # TODO(knn): Remove this once grit has rolled to recognize the flag.
- depend_on_stamp =
- defined(invoker.depend_on_stamp) && invoker.depend_on_stamp
- if (depend_on_stamp) {
- # Need this for migrating existing targets without clobbering.
- depfile = "$output_dir/${grit_output_name}_stamp.d"
- outputs = [
- "${depfile}.stamp",
- ]
- } else {
- depfile = "$output_dir/${grit_output_name}.d"
- outputs = []
- }
- outputs += grit_outputs
+ depfile = "$output_dir/${grit_output_name}_stamp.d"
+ outputs = [ "${depfile}.stamp" ] + grit_outputs
args = [
"-i",
@@ -398,18 +393,15 @@ template("grit") {
]
}
args += [
- "-o",
- rebased_output_dir,
- "--depdir",
- ".",
- "--depfile",
- rebase_path(depfile, root_build_dir),
- "--write-only-new=1",
- ]
- if (depend_on_stamp) {
- args += [ "--depend-on-stamp" ]
- }
- args += grit_defines
+ "-o",
+ rebased_output_dir,
+ "--depdir",
+ ".",
+ "--depfile",
+ rebase_path(depfile, root_build_dir),
+ "--write-only-new=1",
+ "--depend-on-stamp",
+ ] + grit_defines
# Add extra defines with -D flags.
if (defined(invoker.defines)) {
« no previous file with comments | « build/secondary/third_party/sfntly/BUILD.gn ('k') | build/toolchain/gcc_toolchain.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698