mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 11:40:06 +02:00
Telegram: bump version
* build with clang9 (gcc8 fail)
This commit is contained in:
@@ -1,14 +1,14 @@
|
||||
From b1543183b2e9b4fac771107920c7532e5bf5821e Mon Sep 17 00:00:00 2001
|
||||
From fec486f3e53656766d82b43a9d3e9c8de8c089aa Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Sat, 27 Feb 2021 19:35:13 +1000
|
||||
Subject: Add haiku support
|
||||
|
||||
|
||||
diff --git a/Telegram/CMakeLists.txt b/Telegram/CMakeLists.txt
|
||||
index c5ba8fd..302a956 100644
|
||||
index 8a99981..263fc49 100644
|
||||
--- a/Telegram/CMakeLists.txt
|
||||
+++ b/Telegram/CMakeLists.txt
|
||||
@@ -120,6 +120,14 @@ if (LINUX)
|
||||
@@ -121,6 +121,14 @@ if (LINUX)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@@ -23,7 +23,7 @@ index c5ba8fd..302a956 100644
|
||||
target_precompile_headers(Telegram PRIVATE ${src_loc}/stdafx.h)
|
||||
nice_target_sources(Telegram ${src_loc}
|
||||
PRIVATE
|
||||
@@ -1137,6 +1145,16 @@ if (DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
||||
@@ -1132,6 +1140,16 @@ if (DESKTOP_APP_DISABLE_DBUS_INTEGRATION)
|
||||
)
|
||||
endif()
|
||||
|
||||
@@ -40,7 +40,7 @@ index c5ba8fd..302a956 100644
|
||||
if (DESKTOP_APP_DISABLE_WAYLAND_INTEGRATION)
|
||||
remove_target_sources(Telegram ${src_loc} platform/linux/linux_wayland_integration.cpp)
|
||||
nice_target_sources(Telegram ${src_loc} PRIVATE platform/linux/linux_wayland_integration_dummy.cpp)
|
||||
@@ -1263,7 +1281,7 @@ elseif (build_osx)
|
||||
@@ -1258,7 +1276,7 @@ elseif (build_osx)
|
||||
else()
|
||||
set(bundle_identifier "com.tdesktop.Telegram$<$<CONFIG:Debug>:Debug>")
|
||||
set(bundle_entitlements "Telegram.entitlements")
|
||||
@@ -63,10 +63,10 @@ index 732f75b..138608f 100644
|
||||
rpl::variable<bool> _systemDarkModeEnabled = false;
|
||||
WindowPosition _windowPosition; // per-window
|
||||
diff --git a/Telegram/SourceFiles/platform/linux/main_window_linux.cpp b/Telegram/SourceFiles/platform/linux/main_window_linux.cpp
|
||||
index 9796164..d9a2afe 100644
|
||||
index 139667e..81361ef 100644
|
||||
--- a/Telegram/SourceFiles/platform/linux/main_window_linux.cpp
|
||||
+++ b/Telegram/SourceFiles/platform/linux/main_window_linux.cpp
|
||||
@@ -620,11 +620,17 @@ bool MainWindow::hasTrayIcon() const {
|
||||
@@ -651,11 +651,17 @@ bool MainWindow::hasTrayIcon() const {
|
||||
|
||||
bool MainWindow::isActiveForTrayMenu() {
|
||||
updateIsActive();
|
||||
@@ -84,7 +84,7 @@ index 9796164..d9a2afe 100644
|
||||
}
|
||||
|
||||
void MainWindow::psTrayMenuUpdated() {
|
||||
@@ -810,7 +816,9 @@ void MainWindow::psSetupTrayIcon() {
|
||||
@@ -826,7 +832,9 @@ void MainWindow::psSetupTrayIcon() {
|
||||
if (!trayIcon) {
|
||||
trayIcon = new QSystemTrayIcon(this);
|
||||
trayIcon->setIcon(TrayIconGen(counter, muted));
|
||||
@@ -95,7 +95,7 @@ index 9796164..d9a2afe 100644
|
||||
attachToTrayIcon(trayIcon);
|
||||
}
|
||||
updateIconCounters();
|
||||
@@ -893,8 +901,10 @@ void MainWindow::updateIconCounters() {
|
||||
@@ -919,8 +927,10 @@ void MainWindow::updateIconCounters() {
|
||||
}
|
||||
|
||||
void MainWindow::initTrayMenuHook() {
|
||||
@@ -367,10 +367,10 @@ index 0000000..3926290
|
||||
+} // namespace Notifications
|
||||
+} // namespace Platform
|
||||
diff --git a/Telegram/SourceFiles/platform/linux/specific_linux.cpp b/Telegram/SourceFiles/platform/linux/specific_linux.cpp
|
||||
index 386de2e..7bd4dff 100644
|
||||
index f297918..9459434 100644
|
||||
--- a/Telegram/SourceFiles/platform/linux/specific_linux.cpp
|
||||
+++ b/Telegram/SourceFiles/platform/linux/specific_linux.cpp
|
||||
@@ -618,7 +618,7 @@ QString GetHomeDir() {
|
||||
@@ -529,7 +529,7 @@ QString GetHomeDir() {
|
||||
return home;
|
||||
}
|
||||
|
||||
@@ -379,7 +379,7 @@ index 386de2e..7bd4dff 100644
|
||||
void HaikuAutostart(bool start) {
|
||||
const auto home = GetHomeDir();
|
||||
if (home.isEmpty()) {
|
||||
@@ -643,7 +643,7 @@ void HaikuAutostart(bool start) {
|
||||
@@ -554,7 +554,7 @@ void HaikuAutostart(bool start) {
|
||||
file.remove();
|
||||
}
|
||||
}
|
||||
@@ -388,7 +388,7 @@ index 386de2e..7bd4dff 100644
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -660,8 +660,11 @@ QString psAppDataPath() {
|
||||
@@ -571,8 +571,11 @@ QString psAppDataPath() {
|
||||
return oldPath;
|
||||
}
|
||||
}
|
||||
@@ -401,7 +401,7 @@ index 386de2e..7bd4dff 100644
|
||||
}
|
||||
|
||||
void psDoCleanup() {
|
||||
@@ -895,7 +898,7 @@ bool OpenSystemSettings(SystemSettingsType type) {
|
||||
@@ -786,7 +789,7 @@ bool OpenSystemSettings(SystemSettingsType type) {
|
||||
} else if (DesktopEnvironment::IsMATE()) {
|
||||
add("mate-volume-control");
|
||||
}
|
||||
@@ -410,7 +410,7 @@ index 386de2e..7bd4dff 100644
|
||||
add("Media");
|
||||
#endif // __ HAIKU__
|
||||
add("pavucontrol-qt");
|
||||
@@ -958,17 +961,17 @@ void finish() {
|
||||
@@ -835,17 +838,17 @@ void finish() {
|
||||
} // namespace Platform
|
||||
|
||||
void psNewVersion() {
|
||||
@@ -433,10 +433,10 @@ index 386de2e..7bd4dff 100644
|
||||
if (InFlatpak()) {
|
||||
#ifndef DESKTOP_APP_DISABLE_DBUS_INTEGRATION
|
||||
diff --git a/Telegram/lib_ui/ui/platform/linux/ui_utility_linux.cpp b/Telegram/lib_ui/ui/platform/linux/ui_utility_linux.cpp
|
||||
index 80f2ffa..268a0bd 100644
|
||||
index bfcc482..f451bbf 100644
|
||||
--- a/Telegram/lib_ui/ui/platform/linux/ui_utility_linux.cpp
|
||||
+++ b/Telegram/lib_ui/ui/platform/linux/ui_utility_linux.cpp
|
||||
@@ -296,7 +296,7 @@ TitleControls::Layout TitleControlsLayout() {
|
||||
@@ -303,7 +303,7 @@ TitleControls::Layout TitleControlsLayout() {
|
||||
return *gtkResult;
|
||||
}
|
||||
|
||||
@@ -445,7 +445,7 @@ index 80f2ffa..268a0bd 100644
|
||||
return TitleControls::Layout{
|
||||
.left = {
|
||||
TitleControls::Control::Close,
|
||||
@@ -306,7 +306,7 @@ TitleControls::Layout TitleControlsLayout() {
|
||||
@@ -313,7 +313,7 @@ TitleControls::Layout TitleControlsLayout() {
|
||||
TitleControls::Control::Maximize,
|
||||
}
|
||||
};
|
||||
@@ -454,7 +454,7 @@ index 80f2ffa..268a0bd 100644
|
||||
return TitleControls::Layout{
|
||||
.right = {
|
||||
TitleControls::Control::Minimize,
|
||||
@@ -314,7 +314,7 @@ TitleControls::Layout TitleControlsLayout() {
|
||||
@@ -321,7 +321,7 @@ TitleControls::Layout TitleControlsLayout() {
|
||||
TitleControls::Control::Close,
|
||||
}
|
||||
};
|
||||
@@ -464,7 +464,7 @@ index 80f2ffa..268a0bd 100644
|
||||
|
||||
} // namespace Platform
|
||||
diff --git a/Telegram/lib_webrtc/webrtc/details/webrtc_openal_adm.cpp b/Telegram/lib_webrtc/webrtc/details/webrtc_openal_adm.cpp
|
||||
index 410deb3..e0ec769 100644
|
||||
index b8929a5..cd1c61c 100644
|
||||
--- a/Telegram/lib_webrtc/webrtc/details/webrtc_openal_adm.cpp
|
||||
+++ b/Telegram/lib_webrtc/webrtc/details/webrtc_openal_adm.cpp
|
||||
@@ -4,6 +4,13 @@
|
||||
@@ -540,6 +540,23 @@ index 81f9a7b..38d81f9 100644
|
||||
elseif (LINUX)
|
||||
set_source_files_properties(${not_linux_sources} PROPERTIES HEADER_FILE_ONLY TRUE)
|
||||
set_source_files_properties(${not_linux_sources} PROPERTIES SKIP_AUTOGEN TRUE)
|
||||
diff --git a/Telegram/SourceFiles/platform/linux/specific_linux.cpp b/Telegram/SourceFiles/platform/linux/specific_linux.cpp
|
||||
index 9459434..f8d8516 100644
|
||||
--- a/Telegram/SourceFiles/platform/linux/specific_linux.cpp
|
||||
+++ b/Telegram/SourceFiles/platform/linux/specific_linux.cpp
|
||||
@@ -7,6 +7,12 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
*/
|
||||
#include "platform/linux/specific_linux.h"
|
||||
|
||||
+#ifdef __HAIKU__
|
||||
+#define _SUPPORT_DEFS_H
|
||||
+typedef int32 status_t;
|
||||
+typedef uint32 type_code;
|
||||
+#endif
|
||||
+
|
||||
#include "base/openssl_help.h"
|
||||
#include "base/platform/base_platform_info.h"
|
||||
#include "base/platform/linux/base_linux_glibmm_helper.h"
|
||||
--
|
||||
2.30.0
|
||||
2.30.2
|
||||
|
||||
@@ -3,9 +3,9 @@ DESCRIPTION="Unofficial build of the original Telegram client for Haiku."
|
||||
HOMEPAGE="https://www.telegram.org/"
|
||||
COPYRIGHT="2013-2021 Telegram"
|
||||
LICENSE="GNU GPL v3"
|
||||
REVISION="2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/telegramdesktop/tdesktop/releases/download/v$portVersion/tdesktop-$portVersion-full.tar.gz"
|
||||
CHECKSUM_SHA256="c7878c4d7c621a175b3b27895b3fb8c20a56319214d5030d734b2768390a8b73"
|
||||
CHECKSUM_SHA256="ee50aa82e0c0515c2082a37496ffb65c7f83bd117805ee5bf9147c1777770337"
|
||||
SOURCE_FILENAME="tdesktop-$portVersion-full.tar.gz"
|
||||
SOURCE_DIR="tdesktop-$portVersion-full"
|
||||
srcGitRev_2="2b383fe05f8ae78ac99470b9a2b9ea22b3ee5a92"
|
||||
@@ -32,7 +32,9 @@ REQUIRES="
|
||||
lib:libavformat$secondaryArchSuffix
|
||||
lib:libavutil$secondaryArchSuffix
|
||||
lib:libcrypto$secondaryArchSuffix
|
||||
lib:libgiomm_2.4$secondaryArchSuffix
|
||||
lib:libglib_2.0$secondaryArchSuffix
|
||||
lib:libglibmm_2.4$secondaryArchSuffix
|
||||
lib:libgthread_2.0$secondaryArchSuffix
|
||||
lib:libhunspell_1.7$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
@@ -46,6 +48,7 @@ REQUIRES="
|
||||
lib:libQt5Gui$secondaryArchSuffix
|
||||
lib:libQt5Network$secondaryArchSuffix
|
||||
lib:libQt5Widgets$secondaryArchSuffix
|
||||
lib:libsigc_2.0$secondaryArchSuffix
|
||||
lib:libswresample$secondaryArchSuffix
|
||||
lib:libswscale$secondaryArchSuffix
|
||||
lib:libxxhash$secondaryArchSuffix
|
||||
@@ -59,6 +62,7 @@ BUILD_REQUIRES="
|
||||
devel:libavutil$secondaryArchSuffix
|
||||
devel:libcrypto$secondaryArchSuffix
|
||||
devel:libglib_2.0$secondaryArchSuffix
|
||||
devel:libglibmm_2.4$secondaryArchSuffix
|
||||
devel:libgthread_2.0$secondaryArchSuffix
|
||||
devel:libhunspell_1.7$secondaryArchSuffix
|
||||
devel:libjpeg$secondaryArchSuffix
|
||||
@@ -73,6 +77,7 @@ BUILD_REQUIRES="
|
||||
devel:libQt5Network$secondaryArchSuffix
|
||||
devel:libQt5Widgets$secondaryArchSuffix
|
||||
devel:librapidjson$secondaryArchSuffix
|
||||
devel:libstdc++$secondaryArchSuffix
|
||||
devel:libswresample$secondaryArchSuffix
|
||||
devel:libswscale$secondaryArchSuffix
|
||||
devel:libtg_owt$secondaryArchSuffix
|
||||
@@ -83,6 +88,8 @@ BUILD_REQUIRES="
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:cmake
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:clang >= 9
|
||||
cmd:clang++ >= 9
|
||||
cmd:lrelease$secondaryArchSuffix >= 5
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
@@ -93,6 +100,8 @@ BUILD_PREREQUIRES="
|
||||
|
||||
BUILD()
|
||||
{
|
||||
export CC=clang
|
||||
export CXX=clang++
|
||||
export DISABLE_ASLR=1
|
||||
|
||||
# get API_ID and API_HASH from Debian
|
||||
Reference in New Issue
Block a user