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

Unified Diff: tools/gn/substitution_type.h

Issue 1751903003: Add "bundle_data" target as first step for adding bundle support to gn. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@fix-typos
Patch Set: Rebase Created 4 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 | « tools/gn/ninja_target_writer.cc ('k') | tools/gn/substitution_type.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/substitution_type.h
diff --git a/tools/gn/substitution_type.h b/tools/gn/substitution_type.h
index 02787b104648932e0aadd62c1f3e89ff04cdfb45..96ae33a32adf98a84099b6866250d8c70a854b89 100644
--- a/tools/gn/substitution_type.h
+++ b/tools/gn/substitution_type.h
@@ -59,6 +59,12 @@ enum SubstitutionType {
SUBSTITUTION_OUTPUT_EXTENSION, // {{output_extension}}
SUBSTITUTION_SOLIBS, // {{solibs}}
+ // Valid for bundle_data targets.
+ SUBSTITUTION_BUNDLE_ROOT_DIR, // {{bundle_root_dir}}
+ SUBSTITUTION_BUNDLE_RESOURCES_DIR, // {{bundle_resources_dir}}
+ SUBSTITUTION_BUNDLE_EXECUTABLE_DIR, // {{bundle_executable_dir}}
+ SUBSTITUTION_BUNDLE_PLUGINS_DIR, // {{bundle_plugins_dir}}
+
// Used only for the args of actions.
SUBSTITUTION_RSP_FILE_NAME, // {{response_file_name}}
@@ -96,7 +102,13 @@ struct SubstitutionBits {
// verify that they produce a file in the output directory.
bool SubstitutionIsInOutputDir(SubstitutionType type);
+// Returns true if the given substitution pattern references the bundle
+// directory. This is used to check strings that begin with a substitution to
+// verify that they produce a file in the bundle directory.
+bool SubstitutionIsInBundleDir(SubstitutionType type);
+
// Returns true if the given substitution is valid for the named purpose.
+bool IsValidBundleDataSubstitution(SubstitutionType type);
bool IsValidSourceSubstitution(SubstitutionType type);
// Both compiler and linker tools.
bool IsValidToolSubstitution(SubstitutionType type);
« no previous file with comments | « tools/gn/ninja_target_writer.cc ('k') | tools/gn/substitution_type.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698