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

Unified Diff: tools/gn/function_get_path_info.cc

Issue 2198433004: Make get_label_info take into account the toolchain for target_gen_dir (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove unused static function Created 4 years, 4 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 | « tools/gn/function_get_label_info_unittest.cc ('k') | tools/gn/ninja_binary_target_writer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/function_get_path_info.cc
diff --git a/tools/gn/function_get_path_info.cc b/tools/gn/function_get_path_info.cc
index d994f06bde12371ebb96e88e461ae67a6f7a9cc9..c14f4163bf39296b4ade78279959f716717ac9c6 100644
--- a/tools/gn/function_get_path_info.cc
+++ b/tools/gn/function_get_path_info.cc
@@ -88,16 +88,16 @@ std::string GetOnePathInfo(const Settings* settings,
return dir_incl_slash.substr(0, dir_incl_slash.size() - 1).as_string();
}
case WHAT_GEN_DIR: {
- return DirectoryWithNoLastSlash(
- GetGenDirForSourceDir(settings,
- DirForInput(settings, current_dir,
- input, err)));
+ return DirectoryWithNoLastSlash(GetSubBuildDirAsSourceDir(
+ BuildDirContext(settings),
+ DirForInput(settings, current_dir, input, err),
+ BuildDirType::GEN));
}
case WHAT_OUT_DIR: {
- return DirectoryWithNoLastSlash(
- GetOutputDirForSourceDir(settings,
- DirForInput(settings, current_dir,
- input, err)));
+ return DirectoryWithNoLastSlash(GetSubBuildDirAsSourceDir(
+ BuildDirContext(settings),
+ DirForInput(settings, current_dir, input, err),
+ BuildDirType::OBJ));
}
case WHAT_ABSPATH: {
if (!input_string.empty() &&
@@ -168,7 +168,7 @@ const char kGetPathInfo_Help[] =
" The output file directory corresponding to the path of the\n"
" given file, not including a trailing slash.\n"
" \"//foo/bar/baz.txt\" => \"//out/Default/obj/foo/bar\"\n"
-
+ "\n"
" \"gen_dir\"\n"
" The generated file directory corresponding to the path of the\n"
" given file, not including a trailing slash.\n"
« no previous file with comments | « tools/gn/function_get_label_info_unittest.cc ('k') | tools/gn/ninja_binary_target_writer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698