OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef TOOLS_GN_SUBSTITUTION_TYPE_H_ | 5 #ifndef TOOLS_GN_SUBSTITUTION_TYPE_H_ |
6 #define TOOLS_GN_SUBSTITUTION_TYPE_H_ | 6 #define TOOLS_GN_SUBSTITUTION_TYPE_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 class Err; | 10 class Err; |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 | 53 |
54 // Valid for linker tools. | 54 // Valid for linker tools. |
55 SUBSTITUTION_LINKER_INPUTS, // {{inputs}} | 55 SUBSTITUTION_LINKER_INPUTS, // {{inputs}} |
56 SUBSTITUTION_LINKER_INPUTS_NEWLINE, // {{inputs_newline}} | 56 SUBSTITUTION_LINKER_INPUTS_NEWLINE, // {{inputs_newline}} |
57 SUBSTITUTION_LDFLAGS, // {{ldflags}} | 57 SUBSTITUTION_LDFLAGS, // {{ldflags}} |
58 SUBSTITUTION_LIBS, // {{libs}} | 58 SUBSTITUTION_LIBS, // {{libs}} |
59 SUBSTITUTION_OUTPUT_DIR, // {{output_dir}} | 59 SUBSTITUTION_OUTPUT_DIR, // {{output_dir}} |
60 SUBSTITUTION_OUTPUT_EXTENSION, // {{output_extension}} | 60 SUBSTITUTION_OUTPUT_EXTENSION, // {{output_extension}} |
61 SUBSTITUTION_SOLIBS, // {{solibs}} | 61 SUBSTITUTION_SOLIBS, // {{solibs}} |
62 | 62 |
| 63 // Valid for alink only. |
| 64 SUBSTITUTION_ARFLAGS, // {{arflags}} |
| 65 |
63 // Valid for bundle_data targets. | 66 // Valid for bundle_data targets. |
64 SUBSTITUTION_BUNDLE_ROOT_DIR, // {{bundle_root_dir}} | 67 SUBSTITUTION_BUNDLE_ROOT_DIR, // {{bundle_root_dir}} |
65 SUBSTITUTION_BUNDLE_RESOURCES_DIR, // {{bundle_resources_dir}} | 68 SUBSTITUTION_BUNDLE_RESOURCES_DIR, // {{bundle_resources_dir}} |
66 SUBSTITUTION_BUNDLE_EXECUTABLE_DIR, // {{bundle_executable_dir}} | 69 SUBSTITUTION_BUNDLE_EXECUTABLE_DIR, // {{bundle_executable_dir}} |
67 SUBSTITUTION_BUNDLE_PLUGINS_DIR, // {{bundle_plugins_dir}} | 70 SUBSTITUTION_BUNDLE_PLUGINS_DIR, // {{bundle_plugins_dir}} |
68 | 71 |
69 // Used only for the args of actions. | 72 // Used only for the args of actions. |
70 SUBSTITUTION_RSP_FILE_NAME, // {{response_file_name}} | 73 SUBSTITUTION_RSP_FILE_NAME, // {{response_file_name}} |
71 | 74 |
72 SUBSTITUTION_NUM_TYPES // Must be last. | 75 SUBSTITUTION_NUM_TYPES // Must be last. |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 | 113 |
111 // Returns true if the given substitution is valid for the named purpose. | 114 // Returns true if the given substitution is valid for the named purpose. |
112 bool IsValidBundleDataSubstitution(SubstitutionType type); | 115 bool IsValidBundleDataSubstitution(SubstitutionType type); |
113 bool IsValidSourceSubstitution(SubstitutionType type); | 116 bool IsValidSourceSubstitution(SubstitutionType type); |
114 // Both compiler and linker tools. | 117 // Both compiler and linker tools. |
115 bool IsValidToolSubstitution(SubstitutionType type); | 118 bool IsValidToolSubstitution(SubstitutionType type); |
116 bool IsValidCompilerSubstitution(SubstitutionType type); | 119 bool IsValidCompilerSubstitution(SubstitutionType type); |
117 bool IsValidCompilerOutputsSubstitution(SubstitutionType type); | 120 bool IsValidCompilerOutputsSubstitution(SubstitutionType type); |
118 bool IsValidLinkerSubstitution(SubstitutionType type); | 121 bool IsValidLinkerSubstitution(SubstitutionType type); |
119 bool IsValidLinkerOutputsSubstitution(SubstitutionType type); | 122 bool IsValidLinkerOutputsSubstitution(SubstitutionType type); |
| 123 bool IsValidALinkSubstitution(SubstitutionType type); |
120 bool IsValidCopySubstitution(SubstitutionType type); | 124 bool IsValidCopySubstitution(SubstitutionType type); |
121 bool IsValidCompileXCassetsSubstitution(SubstitutionType type); | 125 bool IsValidCompileXCassetsSubstitution(SubstitutionType type); |
122 | 126 |
123 // Like the "IsValid..." version above but checks a list of types and sets a | 127 // Like the "IsValid..." version above but checks a list of types and sets a |
124 // an error blaming the given source if the test fails. | 128 // an error blaming the given source if the test fails. |
125 bool EnsureValidSourcesSubstitutions( | 129 bool EnsureValidSourcesSubstitutions( |
126 const std::vector<SubstitutionType>& types, | 130 const std::vector<SubstitutionType>& types, |
127 const ParseNode* origin, | 131 const ParseNode* origin, |
128 Err* err); | 132 Err* err); |
129 | 133 |
130 #endif // TOOLS_GN_SUBSTITUTION_TYPE_H_ | 134 #endif // TOOLS_GN_SUBSTITUTION_TYPE_H_ |
OLD | NEW |