summaryrefslogtreecommitdiffstats
path: root/qmake/library/qmakevfs.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qmake/library/qmakevfs.cpp')
-rw-r--r--qmake/library/qmakevfs.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/qmake/library/qmakevfs.cpp b/qmake/library/qmakevfs.cpp
index 3a54ef4023..1f77595535 100644
--- a/qmake/library/qmakevfs.cpp
+++ b/qmake/library/qmakevfs.cpp
@@ -35,7 +35,7 @@ using namespace QMakeInternal;
#include <qfile.h>
#include <qfileinfo.h>
-#ifndef QT_NO_TEXTCODEC
+#if QT_CONFIG(textcodec)
#include <qtextcodec.h>
#endif
@@ -49,7 +49,7 @@ QMakeVfs::QMakeVfs()
, m_magicExisting(fL1S("existing"))
#endif
{
-#ifndef QT_NO_TEXTCODEC
+#if QT_CONFIG(textcodec)
m_textCodec = 0;
#endif
ref();
@@ -109,10 +109,10 @@ int QMakeVfs::idForFileName(const QString &fn, VfsFlags flags)
return id;
}
#endif
- if (!(flags & VfsAccessedOnly)) {
#ifdef PROPARSER_THREAD_SAFE
- QMutexLocker locker(&s_mutex);
+ QMutexLocker locker(&s_mutex);
#endif
+ if (!(flags & VfsAccessedOnly)) {
int &id = s_fileIdMap[fn];
if (!id) {
id = ++s_fileIdCounter;
@@ -236,7 +236,7 @@ QMakeVfs::ReadResult QMakeVfs::readFile(int id, QString *contents, QString *errS
return ReadOtherError;
}
*contents =
-#ifndef QT_NO_TEXTCODEC
+#if QT_CONFIG(textcodec)
m_textCodec ? m_textCodec->toUnicode(bcont) :
#endif
QString::fromLocal8Bit(bcont);
@@ -290,7 +290,7 @@ void QMakeVfs::invalidateContents()
}
#endif
-#ifndef QT_NO_TEXTCODEC
+#if QT_CONFIG(textcodec)
void QMakeVfs::setTextCodec(const QTextCodec *textCodec)
{
m_textCodec = textCodec;