forked from qt-creator/qt-creator
CMake: Drop two use of HostOsInfo::isXXXHost
More friendly to docker. Change-Id: I3eeb859cc880fa24c2b1c74caf5a06ec4f27cb2f Reviewed-by: Cristian Adam <cristian.adam@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -234,7 +234,7 @@ FilePath CMakeTool::qchFilePath() const
|
||||
|
||||
FilePath CMakeTool::cmakeExecutable(const FilePath &path)
|
||||
{
|
||||
if (HostOsInfo::isMacHost()) {
|
||||
if (path.osType() == OsTypeMac) {
|
||||
const QString executableString = path.toString();
|
||||
const int appIndex = executableString.lastIndexOf(".app");
|
||||
const int appCutIndex = appIndex + 4;
|
||||
@@ -251,7 +251,7 @@ FilePath CMakeTool::cmakeExecutable(const FilePath &path)
|
||||
|
||||
const FilePath resolvedPath = path.canonicalPath();
|
||||
// Evil hack to make snap-packages of CMake work. See QTCREATORBUG-23376
|
||||
if (HostOsInfo::isLinuxHost() && resolvedPath.fileName() == "snap")
|
||||
if (path.osType() == OsTypeLinux && resolvedPath.fileName() == "snap")
|
||||
return path;
|
||||
|
||||
return resolvedPath;
|
||||
|
Reference in New Issue
Block a user