diff --git a/src/player/CodecsComponent.cpp b/src/player/CodecsComponent.cpp index 1e62d91..a99b212 100644 --- a/src/player/CodecsComponent.cpp +++ b/src/player/CodecsComponent.cpp @@ -116,6 +116,8 @@ static QString getEAEBuildType() return "linux-raspi2-arm7"; #elif defined(Q_OS_LINUX) return sizeof(void *) > 4 ? "linux-ubuntu-x86_64" : "linux-ubuntu-i686"; +#elif defined(Q_OS_FREEBSD) + return sizeof(void *) > 4 ? "FreeBSD-amd64" : "FreeBSD-i386"; #else return "unknown"; #endif diff --git a/src/system/SystemComponent.cpp b/src/system/SystemComponent.cpp index 48aa32c..3d64079 100644 --- a/src/system/SystemComponent.cpp +++ b/src/system/SystemComponent.cpp @@ -42,6 +42,7 @@ QMap g_platformTypeNames = { \ { SystemComponent::platformTypeWindows, "windows" }, { SystemComponent::platformTypeLinux, "linux" }, { SystemComponent::platformTypeOpenELEC, "openelec" }, + { SystemComponent::platformTypeFreeBSD, "freebsd" }, { SystemComponent::platformTypeUnknown, "unknown" }, }; @@ -79,6 +80,8 @@ SystemComponent::SystemComponent(QObject* parent) : ComponentBase(parent), m_pla m_platformType = platformTypeOpenELEC; #elif defined(Q_OS_LINUX) m_platformType = platformTypeLinux; +#elif defined(Q_OS_FREEBSD) + m_platformType = platformTypeFreeBSD; #endif // define target type diff --git a/src/system/SystemComponent.h b/src/system/SystemComponent.h index 94d277d..58920c2 100644 --- a/src/system/SystemComponent.h +++ b/src/system/SystemComponent.h @@ -26,6 +26,7 @@ public: Q_PROPERTY(bool isMacos READ platformIsMac CONSTANT) Q_PROPERTY(bool isWindows READ platformIsWindows CONSTANT) Q_PROPERTY(bool isLinux READ platformIsLinux CONSTANT) + Q_PROPERTY(bool isFreeBSD READ platformIsFreeBSD CONSTANT) Q_PROPERTY(qreal scale MEMBER m_scale CONSTANT) bool componentExport() override { return true; } @@ -81,7 +82,8 @@ public: platformTypeOsx, platformTypeWindows, platformTypeLinux, - platformTypeOpenELEC + platformTypeOpenELEC, + platformTypeFreeBSD }; // possible values for target types @@ -124,6 +126,7 @@ private: bool platformIsWindows() const { return m_platformType == platformTypeWindows; } bool platformIsMac() const { return m_platformType == platformTypeOsx; } bool platformIsLinux() const { return m_platformType == platformTypeLinux; } + bool platformIsFreeBSD() const { return m_platformType == platformTypeFreeBSD; } QSslConfiguration getSSLConfiguration(); void setReplyTimeout(QNetworkReply* reply, int ms);