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 #include "tools/gn/target.h" | 5 #include "tools/gn/target.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 | 10 |
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
293 } | 293 } |
294 | 294 |
295 PullRecursiveBundleData(); | 295 PullRecursiveBundleData(); |
296 PullDependentTargetLibs(); | 296 PullDependentTargetLibs(); |
297 PullRecursiveHardDeps(); | 297 PullRecursiveHardDeps(); |
298 if (!ResolvePrecompiledHeaders(err)) | 298 if (!ResolvePrecompiledHeaders(err)) |
299 return false; | 299 return false; |
300 | 300 |
301 FillOutputFiles(); | 301 FillOutputFiles(); |
302 | 302 |
303 if (settings()->build_settings()->check_for_bad_items()) { | 303 if (!CheckVisibility(err)) |
304 if (!CheckVisibility(err)) | 304 return false; |
305 return false; | 305 if (!CheckTestonly(err)) |
306 if (!CheckTestonly(err)) | 306 return false; |
307 return false; | 307 if (!CheckAssertNoDeps(err)) |
308 if (!CheckAssertNoDeps(err)) | 308 return false; |
309 return false; | 309 CheckSourcesGenerated(); |
310 CheckSourcesGenerated(); | |
311 } | |
312 | 310 |
313 if (!write_runtime_deps_output_.value().empty()) | 311 if (!write_runtime_deps_output_.value().empty()) |
314 g_scheduler->AddWriteRuntimeDepsTarget(this); | 312 g_scheduler->AddWriteRuntimeDepsTarget(this); |
315 | 313 |
316 return true; | 314 return true; |
317 } | 315 } |
318 | 316 |
319 bool Target::IsBinary() const { | 317 bool Target::IsBinary() const { |
320 return output_type_ == EXECUTABLE || | 318 return output_type_ == EXECUTABLE || |
321 output_type_ == SHARED_LIBRARY || | 319 output_type_ == SHARED_LIBRARY || |
(...skipping 448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
770 check_data_deps = g_scheduler->IsFileGeneratedByWriteRuntimeDeps(out_file); | 768 check_data_deps = g_scheduler->IsFileGeneratedByWriteRuntimeDeps(out_file); |
771 // Check object files (much slower and very rare) only if the "normal" | 769 // Check object files (much slower and very rare) only if the "normal" |
772 // output check failed. | 770 // output check failed. |
773 consider_object_files = !check_data_deps; | 771 consider_object_files = !check_data_deps; |
774 if (!EnsureFileIsGeneratedByDependency(this, out_file, true, | 772 if (!EnsureFileIsGeneratedByDependency(this, out_file, true, |
775 consider_object_files, | 773 consider_object_files, |
776 check_data_deps, &seen_targets)) | 774 check_data_deps, &seen_targets)) |
777 g_scheduler->AddUnknownGeneratedInput(this, source); | 775 g_scheduler->AddUnknownGeneratedInput(this, source); |
778 } | 776 } |
779 } | 777 } |
OLD | NEW |