forked from qt-creator/qt-creator
CMake: Make sure source/build directories are reachable
Change-Id: Iea4547807b3a59eb9a8cb70d51d9015dbc8013e3 Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -55,6 +55,15 @@ void CMakeProcess::run(const BuildDirParameters ¶meters, const QStringList &
|
||||
|
||||
const FilePath cmakeExecutable = cmake->cmakeExecutable();
|
||||
|
||||
if (!cmakeExecutable.ensureReachable(parameters.sourceDirectory)
|
||||
|| !cmakeExecutable.ensureReachable(parameters.buildDirectory)) {
|
||||
QString msg = ::CMakeProjectManager::Internal::CMakeProcess::tr(
|
||||
"The source or build directory is not reachable by the CMake executable.");
|
||||
BuildSystem::appendBuildSystemOutput(msg + '\n');
|
||||
emit finished();
|
||||
return;
|
||||
}
|
||||
|
||||
const FilePath sourceDirectory = parameters.sourceDirectory.onDevice(cmakeExecutable);
|
||||
const FilePath buildDirectory = parameters.buildDirectory.onDevice(cmakeExecutable);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user