CMakeProjectManager: Fix issues with precompiled headers

Clang code model can break if CMake project uses precompiled headers.

QtCreator will make a copy of the precompiled header, this way it
will not conflict with the build system one.

Ammends 888ea6bbbb

Fixes: QTCREATORBUG-24945
Fixes: QTCREATORBUG-25213
Change-Id: I149fc416cd047683d095758a024de47c7baf681c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Cristian Adam
2021-01-11 15:57:16 +01:00
parent a64defa10b
commit 98b92ed03e
5 changed files with 81 additions and 47 deletions

View File

@@ -189,6 +189,8 @@ public:
const FilePath &tgtFilePath,
QString *error,
T &&copyHelper);
static bool copyIfDifferent(const FilePath &srcFilePath,
const FilePath &tgtFilePath);
static FilePath resolveSymlinks(const FilePath &path);
static QString fileSystemFriendlyName(const QString &name);
static int indexOfQmakeUnfriendly(const QString &name, int startpos = 0);