CMake: Run cmake with all arguments when no CMakeCache.txt file is found

Always run cmake with all arguments when no CMakeCache.txt file is
found. This allows for the builddirreaders to become a bit simpler.

Change-Id: I67839fd560fb77f6832b1cefc3ff016baa6bae89
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Tobias Hunger
2019-06-07 17:11:03 +02:00
parent 23e30a03c5
commit d5383c92a8

View File

@@ -285,7 +285,9 @@ void BuildDirManager::parse(int reparseParameters)
TaskHub::clearTasks(ProjectExplorer::Constants::TASK_CATEGORY_BUILDSYSTEM);
if (reparseParameters & REPARSE_CHECK_CONFIGURATION) {
if (m_parameters.workDirectory.toFileInfo().exists("CMakeCache.txt")) {
reparseParameters |= REPARSE_FORCE_CONFIGURATION | REPARSE_FORCE_CMAKE_RUN;
} else if (reparseParameters & REPARSE_CHECK_CONFIGURATION) {
if (checkConfiguration())
reparseParameters |= REPARSE_FORCE_CONFIGURATION;
}