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 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
434 if (scheduler_.verbose_logging()) | 434 if (scheduler_.verbose_logging()) |
435 scheduler_.Log("Using source root", FilePathToUTF8(root_path)); | 435 scheduler_.Log("Using source root", FilePathToUTF8(root_path)); |
436 build_settings_.SetRootPath(root_path); | 436 build_settings_.SetRootPath(root_path); |
437 | 437 |
438 return true; | 438 return true; |
439 } | 439 } |
440 | 440 |
441 bool Setup::FillBuildDir(const std::string& build_dir, bool require_exists) { | 441 bool Setup::FillBuildDir(const std::string& build_dir, bool require_exists) { |
442 SourceDir resolved = | 442 SourceDir resolved = |
443 SourceDirForCurrentDirectory(build_settings_.root_path()). | 443 SourceDirForCurrentDirectory(build_settings_.root_path()). |
444 ResolveRelativeDir(build_dir); | 444 ResolveRelativeDir(build_dir, build_settings_.root_path_utf8()); |
445 if (resolved.is_null()) { | 445 if (resolved.is_null()) { |
446 Err(Location(), "Couldn't resolve build directory.", | 446 Err(Location(), "Couldn't resolve build directory.", |
447 "The build directory supplied (\"" + build_dir + "\") was not valid."). | 447 "The build directory supplied (\"" + build_dir + "\") was not valid."). |
448 PrintToStdout(); | 448 PrintToStdout(); |
449 return false; | 449 return false; |
450 } | 450 } |
451 | 451 |
452 if (scheduler_.verbose_logging()) | 452 if (scheduler_.verbose_logging()) |
453 scheduler_.Log("Using build dir", resolved.value()); | 453 scheduler_.Log("Using build dir", resolved.value()); |
454 | 454 |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
604 } | 604 } |
605 | 605 |
606 void DependentSetup::RunPreMessageLoop() { | 606 void DependentSetup::RunPreMessageLoop() { |
607 CommonSetup::RunPreMessageLoop(); | 607 CommonSetup::RunPreMessageLoop(); |
608 } | 608 } |
609 | 609 |
610 bool DependentSetup::RunPostMessageLoop() { | 610 bool DependentSetup::RunPostMessageLoop() { |
611 return CommonSetup::RunPostMessageLoop(); | 611 return CommonSetup::RunPostMessageLoop(); |
612 } | 612 } |
613 | 613 |
OLD | NEW |