Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
2.4.2
-
None
-
Windows, Visual Studio 2017
-
-
aba170a4a32c3635311355f2d01b9e6475af0a22
Description
We are using the unity(jumbo) build system of Visual Studio 2017, as described here in this blog:https://devblogs.microsoft.com/cppblog/support-for-unity-jumbo-files-in-visual-studio-2017-15-8-experimental/
This was working flawlessly with Qt Visual Studio Tools, until version 2.4.2. Now the Qt tools are doing something strange, which is causing an incorrect unity build file, causing compilation to fail.
I have attached a sample project in which the build is failing, which would work with Qt Visual Studio Tools 2.4.1.12.
Build output:
1>------ Rebuild All started: Project: UnityProject, Configuration: Debug Win32 ------
1>Reading Qt configuration (C:\Qt\5.9.3\win32-msvc2017\bin\qmake.exe)
1>unity_R8DXOHMFGGBDD0ZH.cpp
1>c:\projects\tmp\unityproject\unityproject\debug\unity_r8dxohmfggbdd0zh.cpp(5): fatal error C1083: Cannot open include file: 'C:\Projects\tmp\UnityProject\UnityProject\DefaultClCompile': No such file or directory
1>Done building project "UnityProject.vcxproj" – FAILED.
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
Things are going wrong in the unity file generated by Visual Studio, 'unity_[id].cpp':
#include "C:\Projects\tmp\UnityProject\UnityProject\UnityProject.cpp"
#include "C:\Projects\tmp\UnityProject\UnityProject\DefaultClCompile"
The last line should not be there, due to the new version of Qt VS Tools 'DefaultClCompile' gets included.
Could this be caused by target changes in the VS tools?
Attached the sample project to this issue.
Visual Studio version: 2017 Professional, 15.9.14