Commit 059e1df3 authored by Joerg Bornemann's avatar Joerg Bornemann Committed by Jani Heikkinen
Browse files

fix PCH related regression in vcxproj generator

When PRECOMPILED_HEADER is set to foo/bar/stable.h and
PRECOMPILED_SOURCE is empty, then a C++ file foo/bar/stable.cpp
is generated that contains the include "stable.h".
We must pass the exact string "stable.h" to the /Yc compile
switch instead of "foo/bar/stable.h".
Commit dc612acd

 introduced this
regression to allow to have PRECOMPILED_SOURCE in a different
directory than PRECOMPILED_HEADER.

Change-Id: I1a7e096c0455b946a5660d23c70c72abd4c7ac1b
Task-number: QTBUG-46679
Reviewed-by: default avatarOswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: default avatarJoerg Bornemann <joerg.bornemann@theqtcompany.com>
Showing with 2 additions and 0 deletions
......@@ -2238,6 +2238,8 @@ void VCFilter::modifyPCHstage(QString str)
CompilerTool.UsePrecompiledHeader = (isCFile ? pchNone : pchCreateUsingSpecific);
if (isCFile)
CompilerTool.PrecompiledHeaderThrough = QLatin1String("$(NOINHERIT)");
else if (autogenSourceFile)
CompilerTool.PrecompiledHeaderThrough = Project->precompHFilename;
CompilerTool.ForcedIncludeFiles = QStringList("$(NOINHERIT)");
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment