mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-04 16:56:53 +08:00
Change the operating system name from OSX to MacOS everywhere
Summary: - Changed the name in all build artifacts - Everywhere in C++ Reviewers: #swift_pilot_client, kbasan Reviewed By: #swift_pilot_client, kbasan Subscribers: jenkins Maniphest Tasks: T205 Differential Revision: https://dev.swift-project.org/D69
This commit is contained in:
@@ -59,9 +59,14 @@ namespace BlackMisc
|
||||
{
|
||||
if (!p.contains("linux", Qt::CaseInsensitive)) continue;
|
||||
}
|
||||
else if (CBuildConfig::isRunningOnMacOSXPlatform())
|
||||
else if (CBuildConfig::isRunningOnMacOSPlatform())
|
||||
{
|
||||
if (!(p.contains("mac", Qt::CaseInsensitive) || p.contains("osx", Qt::CaseInsensitive))) continue;
|
||||
if (!(p.contains("mac", Qt::CaseInsensitive) ||
|
||||
p.contains("macos", Qt::CaseInsensitive) ||
|
||||
p.contains("osx", Qt::CaseInsensitive)))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
}
|
||||
reduced << p;
|
||||
}
|
||||
|
||||
@@ -51,9 +51,9 @@ namespace BlackMisc
|
||||
Q_ASSERT_X(CBuildConfig::isKnownExecutableName(executable), Q_FUNC_INFO, "Unknown exectuable");
|
||||
|
||||
QString s = CFileUtils::appendFilePaths(CDirectoryUtils::binDirectory(), executable);
|
||||
if (CBuildConfig::isRunningOnMacOSXPlatform())
|
||||
if (CBuildConfig::isRunningOnMacOSPlatform())
|
||||
{
|
||||
// Mac OSX bundle may or may not be a bundle
|
||||
// MacOS bundle may or may not be a bundle
|
||||
const QDir dir(s + QLatin1String(".app/Contents/MacOS"));
|
||||
if (dir.exists())
|
||||
{
|
||||
@@ -82,9 +82,9 @@ namespace BlackMisc
|
||||
return appDir;
|
||||
}
|
||||
|
||||
bool CDirectoryUtils::isMacOSXAppBundle()
|
||||
bool CDirectoryUtils::isMacOSAppBundle()
|
||||
{
|
||||
static const bool appBundle = CBuildConfig::isRunningOnMacOSXPlatform() &&
|
||||
static const bool appBundle = CBuildConfig::isRunningOnMacOSPlatform() &&
|
||||
qApp->applicationDirPath().contains("Contents/MacOS", Qt::CaseInsensitive);
|
||||
return appBundle;
|
||||
}
|
||||
|
||||
@@ -46,9 +46,9 @@ namespace BlackMisc
|
||||
//! swift application data sub directories
|
||||
static QStringList applicationDataDirectoryList(bool withoutCurrent = false, bool beautify = false);
|
||||
|
||||
//! Is MacOSX application bundle?
|
||||
//! \remark: Means the currently running executable is a MacOSX bundle, but not all our executables are bundles on MacOSX
|
||||
static bool isMacOSXAppBundle();
|
||||
//! Is MacOS application bundle?
|
||||
//! \remark: Means the currently running executable is a MacOS bundle, but not all our executables are bundles on MacOS
|
||||
static bool isMacOSAppBundle();
|
||||
|
||||
//! swift application data directory for one specific installation (a version)
|
||||
static const QString &normalizedApplicationDataDirectory();
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
#include <QFileInfo>
|
||||
#include <type_traits>
|
||||
|
||||
#if defined(Q_OS_OSX)
|
||||
#if defined(Q_OS_MACOS)
|
||||
#include <libproc.h>
|
||||
#elif defined(Q_OS_WIN)
|
||||
#include <windows.h>
|
||||
@@ -33,7 +33,7 @@ namespace BlackMisc
|
||||
QString path = QFileInfo(QString("/proc/%1/exe").arg(pid)).symLinkTarget();
|
||||
return QFileInfo(path).fileName();
|
||||
}
|
||||
#elif defined(Q_OS_OSX)
|
||||
#elif defined(Q_OS_MACOS)
|
||||
QString CProcessInfo::processNameFromId(qint64 pid)
|
||||
{
|
||||
char name[1024];
|
||||
|
||||
Reference in New Issue
Block a user