mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-31 04:25:35 +08:00
Added constexpr specifier where possible in CBuildConfig.
This necessitated moving some function definitions into a .inc file that is included by buildconfig.h, as constexpr functions must be defined in the header. This new file is added to the list of QMAKE_SUBSTITUTES.
This commit is contained in:
@@ -24,16 +24,6 @@
|
||||
|
||||
namespace BlackConfig
|
||||
{
|
||||
bool CBuildConfig::isCompiledWithMsFlightSimulatorSupport()
|
||||
{
|
||||
return CBuildConfig::isCompiledWithFs9Support() || CBuildConfig::isCompiledWithFsxSupport() || CBuildConfig::isCompiledWithP3DSupport();
|
||||
}
|
||||
|
||||
bool CBuildConfig::isCompiledWithFlightSimulatorSupport()
|
||||
{
|
||||
return CBuildConfig::isCompiledWithFsxSupport() || CBuildConfig::isCompiledWithXPlaneSupport();
|
||||
}
|
||||
|
||||
const QString &CBuildConfig::swiftGuiExecutableName()
|
||||
{
|
||||
static const QString s("swiftguistd");
|
||||
@@ -59,16 +49,6 @@ namespace BlackConfig
|
||||
executable == CBuildConfig::swiftGuiExecutableName();
|
||||
}
|
||||
|
||||
bool CBuildConfig::isRunningOnWindowsNtPlatform()
|
||||
{
|
||||
#ifdef Q_OS_WIN
|
||||
// QSysInfo::WindowsVersion only available on Win platforms
|
||||
return (QSysInfo::WindowsVersion & QSysInfo::WV_NT_based);
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CBuildConfig::isRunningOnWindows10()
|
||||
{
|
||||
#ifdef Q_OS_WIN
|
||||
@@ -80,29 +60,6 @@ namespace BlackConfig
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CBuildConfig::isRunningOnMacOSPlatform()
|
||||
{
|
||||
#ifdef Q_OS_MACOS
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CBuildConfig::isRunningOnLinuxPlatform()
|
||||
{
|
||||
#ifdef Q_OS_LINUX
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CBuildConfig::isRunningOnUnixPlatform()
|
||||
{
|
||||
return CBuildConfig::isRunningOnMacOSPlatform() || CBuildConfig::isRunningOnLinuxPlatform();
|
||||
}
|
||||
|
||||
const QString &CBuildConfig::getPlatformString()
|
||||
{
|
||||
static const QString p([]
|
||||
@@ -119,24 +76,6 @@ namespace BlackConfig
|
||||
return p;
|
||||
}
|
||||
|
||||
bool CBuildConfig::isDebugBuild()
|
||||
{
|
||||
#ifdef QT_DEBUG
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CBuildConfig::isReleaseBuild()
|
||||
{
|
||||
#ifdef QT_NO_DEBUG
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
namespace Private
|
||||
{
|
||||
bool isLocalDeveloperBuildImpl()
|
||||
|
||||
Reference in New Issue
Block a user