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

Unified Diff: tools/gn/variables.cc

Issue 1155303008: Allow directories for GN data lists. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@path
Patch Set: add dir test Created 5 years, 7 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/target_generator.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/variables.cc
diff --git a/tools/gn/variables.cc b/tools/gn/variables.cc
index 1cbfc9cfb9b894b512ee7ae28b8a6908bc72a915..51a68d5728779ad5039c6847b5e2a9c5e3c5704a 100644
--- a/tools/gn/variables.cc
+++ b/tools/gn/variables.cc
@@ -509,11 +509,11 @@ const char kData_HelpShort[] =
const char kData_Help[] =
"data: Runtime data file dependencies.\n"
"\n"
- " Lists files required to run the given target. These are typically\n"
- " data files. The paths are interpreted as being relative to the current\n"
- " build file. Since these are runtime dependencies, they do not affect\n"
- " which targets are built or when. To declare input files to a script,\n"
- " use \"inputs\".\n"
+ " Lists files or directories required to run the given target. These are\n"
+ " typically data files or directories of data files. The paths are\n"
+ " interpreted as being relative to the current build file. Since these\n"
+ " are runtime dependencies, they do not affect which targets are built\n"
+ " or when. To declare input files to a script, use \"inputs\".\n"
"\n"
" Appearing in the \"data\" section does not imply any special handling\n"
" such as copying them to the output directory. This is just used for\n"
@@ -526,6 +526,11 @@ const char kData_Help[] =
" generated files both in the \"outputs\" list as well as the \"data\"\n"
" list.\n"
"\n"
+ " By convention, directories are be listed with a trailing slash:\n"
+ " data = [ \"test/data/\" ]\n"
+ " However, no verification is done on these so GN doesn't enforce this.\n"
+ " The paths are just rebased and passed along when requested.\n"
+ "\n"
" See \"gn help runtime_deps\" for how these are used.\n";
const char kDataDeps[] = "data_deps";
« no previous file with comments | « tools/gn/target_generator.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698