From 2f61e1b4f4210884c017a5c8c031fffb5c1eddcb Mon Sep 17 00:00:00 2001 From: Jacob Dufault Date: Wed, 5 Apr 2017 18:12:29 -0700 Subject: [PATCH] normalize path in -I flag --- src/project.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/project.cc b/src/project.cc index 782c269e..4a5642c9 100644 --- a/src/project.cc +++ b/src/project.cc @@ -42,7 +42,6 @@ std::vector LoadFromDirectoryListing(const std::string& projec static const char *kValueArgs[] = { "--param", "-G", - "-I", "-MF", "-MQ", "-MT", @@ -165,6 +164,11 @@ std::vector LoadCompilationEntriesFromDirectory(const std::str } + if (StartsWith(arg, "-I")) { + std::string path = directory + "/" + arg.substr(2); + path = NormalizePath(path); + arg = "-I" + path; + } entry.args.push_back(arg);