forked from qt-creator/qt-creator
Utils: Make FilePath::refersToExe(...) return the found item
... and use in on the CMake side. Change-Id: Ib215ebc4f87beb67b6a302d0c42e7b955a2fa5b7 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
@@ -70,8 +70,8 @@ static std::vector<std::unique_ptr<CMakeTool>> autoDetectCMakeTools()
|
||||
if (base.isEmpty())
|
||||
continue;
|
||||
const FilePath suspect = base / "cmake";
|
||||
if (suspect.refersToExecutableFile(FilePath::WithAnySuffix))
|
||||
suspects << suspect;
|
||||
if (std::optional<FilePath> foundExe = suspect.refersToExecutableFile(FilePath::WithAnySuffix))
|
||||
suspects << *foundExe;
|
||||
}
|
||||
|
||||
std::vector<std::unique_ptr<CMakeTool>> found;
|
||||
|
||||
Reference in New Issue
Block a user