From a9c0b817d104bf2e2b561f08feb0ee3ca470f08f Mon Sep 17 00:00:00 2001 From: Ilya Fedin Date: Tue, 8 Nov 2022 21:11:28 +0400 Subject: [PATCH] Explain how to build a backward compatible binary on Linux --- docs/building-linux.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/building-linux.md b/docs/building-linux.md index e0b582150f..00682d2b46 100644 --- a/docs/building-linux.md +++ b/docs/building-linux.md @@ -36,6 +36,9 @@ Or, to create a debug build, run (also using [your **api_id** and **api_hash**]( -D TDESKTOP_API_ID=YOUR_API_ID \ -D TDESKTOP_API_HASH=YOUR_API_HASH +If you need a backward compatible binary (running on older OS like the official one), you should build the binary with LTO. +To do this, add `-D CMAKE_INTERPROCEDURAL_OPTIMIZATION=ON` option. + The built files will be in the `out` directory. [api_credentials]: api_credentials.md