diff options
author | Tasuku Suzuki <tasuku.suzuki@qt.io> | 2017-01-21 00:37:35 +0900 |
---|---|---|
committer | Tasuku Suzuki <tasuku.suzuki@qt.io> | 2017-01-27 09:20:29 +0000 |
commit | 6a8eb9ef8d1f310c470ab0bfcdd35ded15c42607 (patch) | |
tree | 8f0579b8d65ac29997282300062fff6c7f7012de /src | |
parent | e0c119ccd4ca49b6fecb708133bb0d3008903560 (diff) |
Fix build without features.temporaryfile
Change-Id: I31bcf56ee0c4ec9285dccb356b03b89e8ce8356a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/qml/compiler/qv4compileddata.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/qml/compiler/qv4compileddata.cpp b/src/qml/compiler/qv4compileddata.cpp index 6aac111897..d8ff22e9ed 100644 --- a/src/qml/compiler/qv4compileddata.cpp +++ b/src/qml/compiler/qv4compileddata.cpp @@ -356,6 +356,7 @@ bool CompilationUnit::saveToDisk(const QUrl &unitUrl, QString *errorString) return false; } +#if QT_CONFIG(temporaryfile) // Foo.qml -> Foo.qmlc QSaveFile cacheFile(cacheFilePath(unitUrl)); if (!cacheFile.open(QIODevice::WriteOnly | QIODevice::Truncate)) { @@ -388,6 +389,10 @@ bool CompilationUnit::saveToDisk(const QUrl &unitUrl, QString *errorString) } return true; +#else + *errorString = QStringLiteral("features.temporaryfile is disabled."); + return false; +#endif // QT_CONFIG(temporaryfile) } bool CompilationUnit::loadFromDisk(const QUrl &url, EvalISelFactory *iselFactory, QString *errorString) |