-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
prebuilt-tdlib: crosscompile to Linux arm64
- Loading branch information
Showing
7 changed files
with
91 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,7 +22,7 @@ a library to create [Telegram][] clients or bots. | |
- The tdjson shared library (`libtdjson.so` on Linux, `libtdjson.dylib` on macOS, `tdjson.dll` on Windows), of TDLib version 1.8.0 or newer | ||
- In rare cases, a C++ compiler and Python installed to build the node addon[^1] | ||
|
||
[^1]: `tdl` is packaged with pre-built addons for Windows (x86_64), GNU/Linux (x86_64, arm64; glibc >= 2.22), and macOS (x86_64, arm64; v10.14+). If a pre-built binary is not available for your system, then the node addon will be built using node-gyp, requiring Python and a C++ toolchain (C++14 is required) to be installed (on Windows, MSVS or Build Tools). Pass `--build-from-source` to never use the pre-built binaries. arm64 binaries are not tested in the CI. Only Linux binaries are statically linked against libstdc++. | ||
[^1]: `tdl` is packaged with pre-built addons for Windows (x86_64), GNU/Linux (x86_64, arm64; glibc >= 2.22), and macOS (x86_64, arm64; v10.14+). If a pre-built binary is not available for your system, then the node addon will be built using node-gyp, requiring Python and a C++ toolchain (C++14 is required) to be installed (on Windows, MSVS or Build Tools). Pass `--build-from-source` to never use the pre-built binaries. arm64 binaries are not tested in the CI. Linux binaries are statically linked against libstdc++. | ||
|
||
<a name="installation"></a> | ||
## Installation | ||
|
@@ -49,11 +49,12 @@ The tdjson shared library should be present in the system search paths | |
Instead of building TDLib from source, you can possibly install pre-built TDLib | ||
libraries distributed through the `prebuilt-tdlib` npm package. An example of | ||
using libraries from `prebuilt-tdlib` is present in the section below. The | ||
supported systems are x86_64 GNU/Linux, x86_64 & arm64 macOS, and x86_64 | ||
Windows. To install `prebuilt-tdlib` for a specific TDLib version, for example | ||
v1.8.30, run `npm install [email protected]`. The available versions of | ||
`prebuilt-tdlib` can be found by running `npm info prebuilt-tdlib dist-tags`. | ||
See the README of [prebuilt-tdlib][] for additional information. | ||
supported systems are x86_64 & arm64 GNU/Linux, x86_64 & arm64 macOS, and | ||
x86_64s Windows. To install `prebuilt-tdlib` for a specific TDLib version | ||
instead of latest, for example v1.8.30, run `npm i [email protected]`. | ||
The available versions of `prebuilt-tdlib` can be found by running | ||
`npm info prebuilt-tdlib dist-tags`. See the README of [prebuilt-tdlib][] for | ||
additional information. | ||
|
||
[prebuilt-tdlib]: packages/prebuilt-tdlib/README.md | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,17 +2,14 @@ | |
|
||
This package distributes pre-built [TDLib][] shared libraries through npm. | ||
The libraries are built on GitHub Actions ([prebuilt-tdlib.yml][]) and published | ||
using [npm publish --provenance][provenance]. | ||
using [npm publish --provenance][npm-provenance]. | ||
|
||
[TDLib]: https://github.com/tdlib/td | ||
[prebuilt-tdlib.yml]: ../../.github/workflows/prebuilt-tdlib.yml | ||
[provenance]: https://docs.npmjs.com/generating-provenance-statements | ||
|
||
The shared libraries are statically linked against OpenSSL and zlib, for one, to | ||
prevent compatibility issues in Node.js. | ||
[npm-provenance]: https://docs.npmjs.com/generating-provenance-statements | ||
|
||
Supported systems: | ||
- Linux x86_64 (requires glibc >= 2.22) | ||
- Linux x86_64, arm64 (requires glibc >= 2.22) | ||
- macOS x86_64, arm64 (universal, requires macOS >= 10.12) | ||
- Windows x86_64 | ||
|
||
|
@@ -37,6 +34,10 @@ The TDLib version is important: there is no backward compatibility and the | |
interface you use may significantly change after an update. It is, though, | ||
recommended to use the latest TDLib version. | ||
|
||
The shared libraries are statically linked against OpenSSL and zlib, for one, to | ||
prevent compatibility issues in Node.js. libstdc++ is also linked statically | ||
(on Linux). | ||
|
||
## Usage | ||
|
||
The `prebuilt-tdlib` package exports a single function `getTdjson`, which | ||
|
@@ -123,9 +124,9 @@ An incomplete list is available below (mostly exceptions or "notable" versions): | |
|
||
Changes to the building process of `prebuilt-tdlib` are noted below. | ||
|
||
### (unreleased) | ||
### 2024-07-19 | ||
|
||
First published as `<unpublished>`. | ||
First published as `[email protected]`. | ||
|
||
The building process is significantly changed in this update. | ||
|
||
|
@@ -142,6 +143,7 @@ The building process is significantly changed in this update. | |
crosscompiled anymore). | ||
- On Linux, TDLib is now built using zig. The minimal glibc version is 2.22 | ||
instead of 2.17. | ||
- Added a crosscompiled prebuild for Linux arm64. | ||
|
||
### 2024-05-08 | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters