52 lines
1.6 KiB
Diff
52 lines
1.6 KiB
Diff
Upstream: Unsuitable (requires re-work into something that doesn't break libc)
|
|
Reason: This is Glibc specific and treating Linux == glibc is harmful
|
|
|
|
diff --git a/Telegram/lib_base/base/platform/linux/base_info_linux.cpp b/Telegram/lib_base/base/platform/linux/base_info_linux.cpp
|
|
index ea9ab61..bbef601 100644
|
|
--- a/Telegram/lib_base/base/platform/linux/base_info_linux.cpp
|
|
+++ b/Telegram/lib_base/base/platform/linux/base_info_linux.cpp
|
|
@@ -13,7 +13,6 @@
|
|
#include <QtCore/QVersionNumber>
|
|
#include <QtCore/QDate>
|
|
#include <QtGui/QGuiApplication>
|
|
-#include <gnu/libc-version.h>
|
|
|
|
namespace Platform {
|
|
namespace {
|
|
@@ -84,8 +74,7 @@ QString SystemVersionPretty() {
|
|
return "Linux "
|
|
+ (list.isEmpty() ? QString() : list[0] + ' ')
|
|
+ (IsWayland() ? "Wayland " : "X11 ")
|
|
- + "glibc "
|
|
- + GetGlibCVersion();
|
|
+ + "musl";
|
|
}
|
|
|
|
QString SystemCountry() {
|
|
@@ -103,10 +92,6 @@ QString SystemLanguage() {
|
|
QDate WhenSystemBecomesOutdated() {
|
|
if (IsLinux32Bit()) {
|
|
return QDate(2020, 9, 1);
|
|
- } else if (const auto version = GetGlibCVersion(); !version.isEmpty()) {
|
|
- if (QVersionNumber::fromString(version) < QVersionNumber(2, 23)) {
|
|
- return QDate(2020, 9, 1); // Older than Ubuntu 16.04.
|
|
- }
|
|
}
|
|
return QDate();
|
|
}
|
|
@@ -129,14 +114,6 @@ QString AutoUpdateKey() {
|
|
}
|
|
}
|
|
|
|
-QString GetGlibCVersion() {
|
|
- static const auto result = [&] {
|
|
- const auto version = QString::fromLatin1(gnu_get_libc_version());
|
|
- return QVersionNumber::fromString(version).isNull() ? QString() : version;
|
|
- }();
|
|
- return result;
|
|
-}
|
|
-
|
|
bool IsWayland() {
|
|
return QGuiApplication::platformName().startsWith("wayland", Qt::CaseInsensitive);
|
|
}
|