From f3456c8f92be2b7c52bae3908bacfa914689cad0 Mon Sep 17 00:00:00 2001 From: Aurindam Jana Date: Thu, 29 Nov 2012 12:20:21 +0100 Subject: [PATCH] Fix build for Qt 5 configured without -developer-build This patch reverts 2b0c1fb376a410df09b85dfd1549f429aa2b9155 and affd4b9ce1774c4e1aba4814891d1d471f202f6c Change-Id: I65daf80a0e510f4103c2f2714a3ee583207e53d0 Reviewed-by: Kai Koehne Reviewed-by: hjk --- src/plugins/coreplugin/coreplugin.pro | 2 +- src/plugins/coreplugin/fileutils.cpp | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/plugins/coreplugin/coreplugin.pro b/src/plugins/coreplugin/coreplugin.pro index e152430c064..381f6a6e573 100644 --- a/src/plugins/coreplugin/coreplugin.pro +++ b/src/plugins/coreplugin/coreplugin.pro @@ -6,7 +6,7 @@ QT += network \ sql greaterThan(QT_MAJOR_VERSION, 4) { - QT += help printsupport core-private + QT += help printsupport } else { CONFIG += help } diff --git a/src/plugins/coreplugin/fileutils.cpp b/src/plugins/coreplugin/fileutils.cpp index 3f3c05b7c20..4f50ee2646d 100644 --- a/src/plugins/coreplugin/fileutils.cpp +++ b/src/plugins/coreplugin/fileutils.cpp @@ -45,8 +45,6 @@ #if QT_VERSION < 0x050000 #include -#else -#include #endif #ifndef Q_OS_WIN @@ -195,9 +193,13 @@ void FileUtils::removeFile(const QString &filePath, bool deleteFromFS) static inline bool fileSystemRenameFile(const QString &orgFilePath, const QString &newFilePath) { +#if QT_VERSION < 0x050000 QAbstractFileEngine *fileEngine = QAbstractFileEngine::create(orgFilePath); // Due to QTBUG-3570 if (!fileEngine->caseSensitive() && orgFilePath.compare(newFilePath, Qt::CaseInsensitive) == 0) return fileEngine->rename(newFilePath); +#endif + // QTBUG-3570 is also valid for Qt 5 but QAbstractFileEngine is now in a private header file and + // the symbol is not exported. return QFile::rename(orgFilePath, newFilePath); }