init
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Close stale issues and PRs / stale (push) Successful in 13s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Close stale issues and PRs / stale (push) Successful in 13s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
This commit is contained in:
13
docs/api_credentials.md
Normal file
13
docs/api_credentials.md
Normal file
@@ -0,0 +1,13 @@
|
||||
## Obtaining your API credentials
|
||||
|
||||
To build your version of Telegram Desktop you're required to provide your own **api_id** and **api_hash** for the Telegram API access.
|
||||
|
||||
How to obtain your **api_id** and **api_hash** is described here: [https://core.telegram.org/api/obtaining_api_id](https://core.telegram.org/api/obtaining_api_id)
|
||||
|
||||
If you're building the application not for deployment, but only for test purposes you can use TEST ONLY credentials, which are very limited by the Telegram API server:
|
||||
|
||||
**api_id**: 17349
|
||||
**api_hash**: 344583e45741c457fe1862106095a5eb
|
||||
|
||||
Your users will start getting internal server errors on login if you deploy an app using those **api_id** and **api_hash**.
|
||||
|
||||
BIN
docs/assets/preview.png
Normal file
BIN
docs/assets/preview.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 MiB |
BIN
docs/assets/slide.01.jpg
Normal file
BIN
docs/assets/slide.01.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 466 KiB |
BIN
docs/assets/slide.02.jpg
Normal file
BIN
docs/assets/slide.02.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 421 KiB |
BIN
docs/assets/slide.03.jpg
Normal file
BIN
docs/assets/slide.03.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 456 KiB |
BIN
docs/assets/slide.04.jpg
Normal file
BIN
docs/assets/slide.04.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 588 KiB |
60
docs/building-linux.md
Normal file
60
docs/building-linux.md
Normal file
@@ -0,0 +1,60 @@
|
||||
## Build instructions for Linux using Docker
|
||||
|
||||
### Prepare folder
|
||||
|
||||
Choose a folder for the future build, for example **/home/user/TBuild**. It will be named ***BuildPath*** in the rest of this document. All commands will be launched from Terminal.
|
||||
|
||||
### Obtain your API credentials
|
||||
|
||||
You will require **api_id** and **api_hash** to access the Telegram API servers. To learn how to obtain them [click here][api_credentials].
|
||||
|
||||
### Clone source code and prepare libraries
|
||||
|
||||
Install [poetry](https://python-poetry.org), go to ***BuildPath*** and run
|
||||
|
||||
git clone --recursive https://github.com/telegramdesktop/tdesktop.git
|
||||
./tdesktop/Telegram/build/prepare/linux.sh
|
||||
|
||||
### Building the project
|
||||
|
||||
Go to ***BuildPath*/tdesktop** and run (using [your **api_id** and **api_hash**](#obtain-your-api-credentials))
|
||||
|
||||
docker run --rm -it \
|
||||
-u $(id -u) \
|
||||
-v "$PWD:/usr/src/tdesktop" \
|
||||
tdesktop:centos_env \
|
||||
/usr/src/tdesktop/Telegram/build/docker/centos_env/build.sh \
|
||||
-D TDESKTOP_API_ID=YOUR_API_ID \
|
||||
-D TDESKTOP_API_HASH=YOUR_API_HASH
|
||||
|
||||
Or, to create a debug build, run (also using [your **api_id** and **api_hash**](#obtain-your-api-credentials))
|
||||
|
||||
docker run --rm -it \
|
||||
-u $(id -u) \
|
||||
-v "$PWD:/usr/src/tdesktop" \
|
||||
-e CONFIG=Debug \
|
||||
tdesktop:centos_env \
|
||||
/usr/src/tdesktop/Telegram/build/docker/centos_env/build.sh \
|
||||
-D TDESKTOP_API_ID=YOUR_API_ID \
|
||||
-D TDESKTOP_API_HASH=YOUR_API_HASH
|
||||
|
||||
The built files will be in the `out` directory.
|
||||
|
||||
### Visual Studio Code integration
|
||||
|
||||
Ensure you've followed the instruction up to the [**Clone source code and prepare libraries**](#clone-source-code-and-prepare-libraries) step at least.
|
||||
|
||||
Open the repository in Visual Studio Code, install the [Dev Containers](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) extension and add the following to `.vscode/settings.json` (using [your **api_id** and **api_hash**](#obtain-your-api-credentials)):
|
||||
|
||||
{
|
||||
"cmake.configureSettings": {
|
||||
"TDESKTOP_API_ID": "YOUR_API_ID",
|
||||
"TDESKTOP_API_HASH": "YOUR_API_HASH"
|
||||
}
|
||||
}
|
||||
|
||||
After that, choose **Reopen in Container** via the menu triggered by the green button in bottom left corner and you're done.
|
||||
|
||||

|
||||
|
||||
[api_credentials]: api_credentials.md
|
||||
35
docs/building-mac.md
Normal file
35
docs/building-mac.md
Normal file
@@ -0,0 +1,35 @@
|
||||
## Build instructions for macOS
|
||||
|
||||
### Prepare folder
|
||||
|
||||
Choose a folder for the future build, for example **/Users/user/TBuild**. It will be named ***BuildPath*** in the rest of this document. All commands will be launched from Terminal.
|
||||
|
||||
**Note about disk space:** The full build process will require approximately **55 GB** of free space. This includes:
|
||||
- **~35 GB** for libraries (when building for both x64 and arm64 architectures)
|
||||
- **~20 GB** for the compiled Telegram app (in the `out` folder)
|
||||
|
||||
### Obtain your API credentials
|
||||
|
||||
You will require **api_id** and **api_hash** to access the Telegram API servers. To learn how to obtain them [click here][api_credentials].
|
||||
|
||||
### Clone source code and prepare libraries
|
||||
|
||||
Go to ***BuildPath*** and run
|
||||
|
||||
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
|
||||
brew install git automake cmake wget pkg-config gnu-tar ninja nasm meson
|
||||
|
||||
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
|
||||
|
||||
git clone --recursive https://github.com/telegramdesktop/tdesktop.git
|
||||
./tdesktop/Telegram/build/prepare/mac.sh
|
||||
|
||||
### Building the project
|
||||
|
||||
Go to ***BuildPath*/tdesktop/Telegram** and run (using [your **api_id** and **api_hash**](#obtain-your-api-credentials))
|
||||
|
||||
./configure.sh -D TDESKTOP_API_ID=YOUR_API_ID -D TDESKTOP_API_HASH=YOUR_API_HASH
|
||||
|
||||
Then launch Xcode, open ***BuildPath*/tdesktop/out/Telegram.xcodeproj** and build for Debug / Release.
|
||||
|
||||
[api_credentials]: api_credentials.md
|
||||
28
docs/building-mas.md
Normal file
28
docs/building-mas.md
Normal file
@@ -0,0 +1,28 @@
|
||||
## Build instructions for Mac App Store
|
||||
|
||||
**NB** These are used for Mac App Store build, after the [Build for macOS][mac] instructions.
|
||||
|
||||
### Prepare breakpad
|
||||
|
||||
Go to ***BuildPath*** and run
|
||||
|
||||
MACOSX_DEPLOYMENT_TARGET=10.12
|
||||
|
||||
cd Libraries
|
||||
|
||||
git clone https://chromium.googlesource.com/breakpad/breakpad
|
||||
cd breakpad
|
||||
git checkout bc8fb886
|
||||
git clone https://chromium.googlesource.com/linux-syscall-support src/third_party/lss
|
||||
cd src/third_party/lss
|
||||
git checkout a91633d1
|
||||
cd ../../..
|
||||
git apply ../patches/breakpad.diff
|
||||
cd src/client/mac
|
||||
xcodebuild -project Breakpad.xcodeproj -target Breakpad -configuration Debug build
|
||||
xcodebuild -project Breakpad.xcodeproj -target Breakpad -configuration Release build
|
||||
cd ../../tools/mac/dump_syms
|
||||
xcodebuild -project dump_syms.xcodeproj -target dump_syms -configuration Release build
|
||||
cd ../../../../..
|
||||
|
||||
[xcode]: building-xcode.md
|
||||
52
docs/building-win-x64.md
Normal file
52
docs/building-win-x64.md
Normal file
@@ -0,0 +1,52 @@
|
||||
# Build instructions for Windows 64-bit
|
||||
|
||||
- [Prepare folder](#prepare-folder)
|
||||
- [Install third party software](#install-third-party-software)
|
||||
- [Clone source code and prepare libraries](#clone-source-code-and-prepare-libraries)
|
||||
- [Build the project](#build-the-project)
|
||||
- [Qt Visual Studio Tools](#qt-visual-studio-tools)
|
||||
|
||||
## Prepare folder
|
||||
|
||||
The build is done in **Visual Studio 2022** with **10.0.26100.0** SDK version.
|
||||
|
||||
Choose an empty folder for the future build, for example **D:\\TBuild**. It will be named ***BuildPath*** in the rest of this document. Create two folders there, ***BuildPath*\\ThirdParty** and ***BuildPath*\\Libraries**.
|
||||
|
||||
All commands (if not stated otherwise) will be launched from **x64 Native Tools Command Prompt for VS 2022.bat** (should be in **Start Menu > Visual Studio 2022** menu folder). Pay attention not to use any other Command Prompt.
|
||||
|
||||
### Obtain your API credentials
|
||||
|
||||
You will require **api_id** and **api_hash** to access the Telegram API servers. To learn how to obtain them [click here][api_credentials].
|
||||
|
||||
## Install third party software
|
||||
|
||||
* Download **Python 3.10** installer from [https://www.python.org/downloads/](https://www.python.org/downloads/) and install it with adding to PATH.
|
||||
* Download **Git** installer from [https://git-scm.com/download/win](https://git-scm.com/download/win) and install it.
|
||||
|
||||
## Clone source code and prepare libraries
|
||||
|
||||
Open **x64 Native Tools Command Prompt for VS 2022.bat**, go to ***BuildPath*** and run
|
||||
|
||||
git clone --recursive https://github.com/telegramdesktop/tdesktop.git
|
||||
tdesktop\Telegram\build\prepare\win.bat
|
||||
|
||||
## Build the project
|
||||
|
||||
Go to ***BuildPath*\\tdesktop\\Telegram** and run (using [your **api_id** and **api_hash**](#obtain-your-api-credentials))
|
||||
|
||||
configure.bat x64 -D TDESKTOP_API_ID=YOUR_API_ID -D TDESKTOP_API_HASH=YOUR_API_HASH
|
||||
|
||||
* Open ***BuildPath*\\tdesktop\\out\\Telegram.sln** in Visual Studio 2022
|
||||
* Select Telegram project and press Build > Build Telegram (Debug and Release configurations)
|
||||
* The result Telegram.exe will be located in **D:\TBuild\tdesktop\out\Debug** (and **Release**)
|
||||
|
||||
### Qt Visual Studio Tools
|
||||
|
||||
For better debugging you may want to install Qt Visual Studio Tools:
|
||||
|
||||
* Open **Extensions** -> **Manage Extensions**
|
||||
* Go to **Online** tab
|
||||
* Search for **Qt**
|
||||
* Install **Qt Visual Studio Tools** extension
|
||||
|
||||
[api_credentials]: api_credentials.md
|
||||
52
docs/building-win.md
Normal file
52
docs/building-win.md
Normal file
@@ -0,0 +1,52 @@
|
||||
# Build instructions for Windows
|
||||
|
||||
- [Prepare folder](#prepare-folder)
|
||||
- [Install third party software](#install-third-party-software)
|
||||
- [Clone source code and prepare libraries](#clone-source-code-and-prepare-libraries)
|
||||
- [Build the project](#build-the-project)
|
||||
- [Qt Visual Studio Tools](#qt-visual-studio-tools)
|
||||
|
||||
## Prepare folder
|
||||
|
||||
The build is done in **Visual Studio 2022** with **10.0.26100.0** SDK version.
|
||||
|
||||
Choose an empty folder for the future build, for example **D:\\TBuild**. It will be named ***BuildPath*** in the rest of this document. Create two folders there, ***BuildPath*\\ThirdParty** and ***BuildPath*\\Libraries**.
|
||||
|
||||
All commands (if not stated otherwise) will be launched from **x86 Native Tools Command Prompt for VS 2022.bat** (should be in **Start Menu > Visual Studio 2022** menu folder). Pay attention not to use any other Command Prompt.
|
||||
|
||||
### Obtain your API credentials
|
||||
|
||||
You will require **api_id** and **api_hash** to access the Telegram API servers. To learn how to obtain them [click here][api_credentials].
|
||||
|
||||
## Install third party software
|
||||
|
||||
* Download **Python 3.10** installer from [https://www.python.org/downloads/](https://www.python.org/downloads/) and install it with adding to PATH.
|
||||
* Download **Git** installer from [https://git-scm.com/download/win](https://git-scm.com/download/win) and install it.
|
||||
|
||||
## Clone source code and prepare libraries
|
||||
|
||||
Open **x86 Native Tools Command Prompt for VS 2022.bat**, go to ***BuildPath*** and run
|
||||
|
||||
git clone --recursive https://github.com/telegramdesktop/tdesktop.git
|
||||
tdesktop\Telegram\build\prepare\win.bat
|
||||
|
||||
## Build the project
|
||||
|
||||
Go to ***BuildPath*\\tdesktop\\Telegram** and run (using [your **api_id** and **api_hash**](#obtain-your-api-credentials))
|
||||
|
||||
configure.bat -D TDESKTOP_API_ID=YOUR_API_ID -D TDESKTOP_API_HASH=YOUR_API_HASH
|
||||
|
||||
* Open ***BuildPath*\\tdesktop\\out\\Telegram.sln** in Visual Studio 2022
|
||||
* Select Telegram project and press Build > Build Telegram (Debug and Release configurations)
|
||||
* The result Telegram.exe will be located in **D:\TBuild\tdesktop\out\Debug** (and **Release**)
|
||||
|
||||
### Qt Visual Studio Tools
|
||||
|
||||
For better debugging you may want to install Qt Visual Studio Tools:
|
||||
|
||||
* Open **Extensions** -> **Manage Extensions**
|
||||
* Go to **Online** tab
|
||||
* Search for **Qt**
|
||||
* Install **Qt Visual Studio Tools** extension
|
||||
|
||||
[api_credentials]: api_credentials.md
|
||||
10
docs/misc.txt
Normal file
10
docs/misc.txt
Normal file
@@ -0,0 +1,10 @@
|
||||
macOS:
|
||||
|
||||
breakpad - clone breakpad like for msvc, including the patch, open breakpad/src/client/mac/Breakpad.xcodeproj and build Release
|
||||
dump_syms - open breakpad/src/tools/mac/dump_syms/dump_syms.xcodeproj and build Release, copy dump_syms from ~/Library/Developer/Xcode/DerivedData/dump_syms-[a-z0-9]+/Build/Products/Release/ to BuildPath/Libraries/breakpad/src/tools/mac/dump_syms/build/Release/
|
||||
minidump_stackwalk - go to Libraries/breakpad, run "configure", run "make"
|
||||
|
||||
Windows:
|
||||
|
||||
install InnoSetup
|
||||
open brekpad/src/tools/windows/dump_syms/dump_syms.vcproj, upgrade, change SDK and build Debug and Release
|
||||
Reference in New Issue
Block a user