| 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/setup.h" | 5 #include "tools/gn/setup.h" |
| 6 | 6 |
| 7 #include <stdlib.h> | 7 #include <stdlib.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <sstream> | 10 #include <sstream> |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 check_for_unused_overrides_(other.check_for_unused_overrides_), | 156 check_for_unused_overrides_(other.check_for_unused_overrides_), |
| 157 check_public_headers_(other.check_public_headers_) { | 157 check_public_headers_(other.check_public_headers_) { |
| 158 loader_->set_complete_callback(base::Bind(&DecrementWorkCount)); | 158 loader_->set_complete_callback(base::Bind(&DecrementWorkCount)); |
| 159 } | 159 } |
| 160 | 160 |
| 161 CommonSetup::~CommonSetup() { | 161 CommonSetup::~CommonSetup() { |
| 162 } | 162 } |
| 163 | 163 |
| 164 void CommonSetup::RunPreMessageLoop() { | 164 void CommonSetup::RunPreMessageLoop() { |
| 165 // Load the root build file. | 165 // Load the root build file. |
| 166 loader_->Load(root_build_file_, Label()); | 166 loader_->Load(root_build_file_, LocationRange(), Label()); |
| 167 | 167 |
| 168 // Will be decremented with the loader is drained. | 168 // Will be decremented with the loader is drained. |
| 169 g_scheduler->IncrementWorkCount(); | 169 g_scheduler->IncrementWorkCount(); |
| 170 } | 170 } |
| 171 | 171 |
| 172 bool CommonSetup::RunPostMessageLoop() { | 172 bool CommonSetup::RunPostMessageLoop() { |
| 173 Err err; | 173 Err err; |
| 174 if (check_for_bad_items_) { | 174 if (check_for_bad_items_) { |
| 175 if (!builder_->CheckForBadItems(&err)) { | 175 if (!builder_->CheckForBadItems(&err)) { |
| 176 err.PrintToStdout(); | 176 err.PrintToStdout(); |
| (...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 596 } | 596 } |
| 597 | 597 |
| 598 void DependentSetup::RunPreMessageLoop() { | 598 void DependentSetup::RunPreMessageLoop() { |
| 599 CommonSetup::RunPreMessageLoop(); | 599 CommonSetup::RunPreMessageLoop(); |
| 600 } | 600 } |
| 601 | 601 |
| 602 bool DependentSetup::RunPostMessageLoop() { | 602 bool DependentSetup::RunPostMessageLoop() { |
| 603 return CommonSetup::RunPostMessageLoop(); | 603 return CommonSetup::RunPostMessageLoop(); |
| 604 } | 604 } |
| 605 | 605 |
| OLD | NEW |