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

Unified Diff: tools/grit/grit/scons.py

Issue 28225: fix the grd scanner to only include files that we're using (Closed)
Patch Set: Created 11 years, 10 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/grit/grit/scons.py
diff --git a/tools/grit/grit/scons.py b/tools/grit/grit/scons.py
index 66d2771dd4633d7b6fe511856d0f81f7aa81da4f..09eb4e51114baca0be0676efc57154f18161163a 100644
--- a/tools/grit/grit/scons.py
+++ b/tools/grit/grit/scons.py
@@ -147,11 +147,8 @@ def _Scanner(file_node, env, path):
node.parent.name == 'translations')):
files.append(os.path.abspath(node.GetFilePath()))
elif node.name == 'include':
- # We depend on all resources specified in the grd file. However, some
- # files are only used by official builds and aren't in the public
- # repository (e.g., the Google Chrome logo). If the file doesn't exist,
- # just don't add it to the file dependencies.
- if os.path.exists(node.FilenameToOpen()):
+ # Only include files that we actually plan on using.
+ if node.SatisfiesOutputCondition():
files.append(node.FilenameToOpen())
# Add in the grit source files. If one of these change, we want to re-run
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698