Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(792)

Unified Diff: webkit/support/webkit_support.cc

Issue 8585029: Make GetWebKitRootDirFilePath smarter about where the WebKit root is relative to the chromium root (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 8 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/base_paths_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/support/webkit_support.cc
diff --git a/webkit/support/webkit_support.cc b/webkit/support/webkit_support.cc
index 7fd667835d7b9936a5fd45a0e9a74ac0f4b77e8b..ad9ccfb341e2cdd351b851812d35cbf8148839e0 100644
--- a/webkit/support/webkit_support.cc
+++ b/webkit/support/webkit_support.cc
@@ -187,11 +187,20 @@ FilePath GetWebKitRootDirFilePath() {
FilePath basePath;
PathService::Get(base::DIR_SOURCE_ROOT, &basePath);
if (file_util::PathExists(basePath.Append(FILE_PATH_LITERAL("chrome")))) {
+ // We're in a WebKit-in-chrome checkout.
return basePath.Append(FILE_PATH_LITERAL("third_party/WebKit"));
- } else {
- // WebKit/Source/WebKit/chromium/ -> WebKit/
+ } else if (file_util::PathExists(
+ basePath.Append(FILE_PATH_LITERAL("chromium")))) {
+ // We're in a WebKit-only checkout on Windows.
+ return basePath.Append(FILE_PATH_LITERAL("../.."));
+ } else if (file_util::PathExists(
+ basePath.Append(FILE_PATH_LITERAL("webkit/support")))) {
+ // We're in a WebKit-only/xcodebuild checkout on Mac
return basePath.Append(FILE_PATH_LITERAL("../../.."));
}
+ // We're in a WebKit-only, make-build, so the DIR_SOURCE_ROOT is already the
+ // WebKit root. That, or we have no idea where we are.
+ return basePath;
}
class WebKitClientMessageLoopImpl
« no previous file with comments | « base/base_paths_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698