forked from qt-creator/qt-creator
CMake: Bark when selected cmake binary and build dir on different hosts
Change-Id: I31d373cb6a87c65dbf42ae4e0b295d41f94d9f63 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
This commit is contained in:
@@ -109,6 +109,13 @@ void CMakeProcess::run(const BuildDirParameters ¶meters, const QStringList &
|
||||
connect(process.get(), &QtcProcess::finished,
|
||||
this, &CMakeProcess::handleProcessFinished);
|
||||
|
||||
if (buildDirectory.needsDevice()) {
|
||||
if (cmake->cmakeExecutable().host() != buildDirectory.host()) {
|
||||
m_parser.appendMessage(tr("CMake executable and build dir must be on the same device."), StdErrFormat);
|
||||
reportCanceled();
|
||||
return;
|
||||
}
|
||||
}
|
||||
CommandLine commandLine(cmake->cmakeExecutable(), QStringList({"-S", srcDir, "-B", buildDirectory.path()}) + arguments);
|
||||
|
||||
TaskHub::clearTasks(ProjectExplorer::Constants::TASK_CATEGORY_BUILDSYSTEM);
|
||||
|
Reference in New Issue
Block a user