OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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_TARGET_H_ | 5 #ifndef TOOLS_GN_TARGET_H_ |
6 #define TOOLS_GN_TARGET_H_ | 6 #define TOOLS_GN_TARGET_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 // This config represents the configuration set directly on this target. | 133 // This config represents the configuration set directly on this target. |
134 ConfigValues& config_values() { return config_values_; } | 134 ConfigValues& config_values() { return config_values_; } |
135 const ConfigValues& config_values() const { return config_values_; } | 135 const ConfigValues& config_values() const { return config_values_; } |
136 | 136 |
137 ScriptValues& script_values() { return script_values_; } | 137 ScriptValues& script_values() { return script_values_; } |
138 const ScriptValues& script_values() const { return script_values_; } | 138 const ScriptValues& script_values() const { return script_values_; } |
139 | 139 |
140 const OrderedSet<SourceDir>& all_lib_dirs() const { return all_lib_dirs_; } | 140 const OrderedSet<SourceDir>& all_lib_dirs() const { return all_lib_dirs_; } |
141 const OrderedSet<std::string>& all_libs() const { return all_libs_; } | 141 const OrderedSet<std::string>& all_libs() const { return all_libs_; } |
142 | 142 |
| 143 const SourceFile& gyp_file() const { return gyp_file_; } |
| 144 void set_gyp_file(const SourceFile& gf) { gyp_file_ = gf; } |
| 145 |
143 private: | 146 private: |
144 // Pulls necessary information from dependents to this one when all | 147 // Pulls necessary information from dependents to this one when all |
145 // dependencies have been resolved. | 148 // dependencies have been resolved. |
146 void PullDependentTargetInfo(std::set<const Config*>* unique_configs); | 149 void PullDependentTargetInfo(std::set<const Config*>* unique_configs); |
147 | 150 |
148 const Settings* settings_; | 151 const Settings* settings_; |
149 OutputType output_type_; | 152 OutputType output_type_; |
150 std::string output_name_; | 153 std::string output_name_; |
151 | 154 |
152 FileList sources_; | 155 FileList sources_; |
(...skipping 29 matching lines...) Expand all Loading... |
182 std::set<const Target*> inherited_libraries_; | 185 std::set<const Target*> inherited_libraries_; |
183 | 186 |
184 // These libs and dirs are inherited from statically linked deps and all | 187 // These libs and dirs are inherited from statically linked deps and all |
185 // configs applying to this target. | 188 // configs applying to this target. |
186 OrderedSet<SourceDir> all_lib_dirs_; | 189 OrderedSet<SourceDir> all_lib_dirs_; |
187 OrderedSet<std::string> all_libs_; | 190 OrderedSet<std::string> all_libs_; |
188 | 191 |
189 ConfigValues config_values_; // Used for all binary targets. | 192 ConfigValues config_values_; // Used for all binary targets. |
190 ScriptValues script_values_; // Used for script (CUSTOM) targets. | 193 ScriptValues script_values_; // Used for script (CUSTOM) targets. |
191 | 194 |
192 SourceDir destdir_; | 195 SourceFile gyp_file_; |
193 | 196 |
194 bool generated_; | 197 bool generated_; |
195 const Token* generator_function_; // Who generated this: for error messages. | 198 const Token* generator_function_; // Who generated this: for error messages. |
196 | 199 |
197 DISALLOW_COPY_AND_ASSIGN(Target); | 200 DISALLOW_COPY_AND_ASSIGN(Target); |
198 }; | 201 }; |
199 | 202 |
200 #endif // TOOLS_GN_TARGET_H_ | 203 #endif // TOOLS_GN_TARGET_H_ |
OLD | NEW |