Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/up9cloud/android-libtdjson
Prebuilt [TDLib](https://github.com/tdlib/td) shared libs (libtdjson.so) for Android
https://github.com/up9cloud/android-libtdjson
android lib libtdjson maven prebuilt tdjson tdlib telegram telegram-api
Last synced: 3 months ago
JSON representation
Prebuilt [TDLib](https://github.com/tdlib/td) shared libs (libtdjson.so) for Android
- Host: GitHub
- URL: https://github.com/up9cloud/android-libtdjson
- Owner: up9cloud
- License: mit
- Created: 2021-06-28T03:28:10.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-06-27T23:06:58.000Z (7 months ago)
- Last Synced: 2024-10-31T12:46:24.864Z (3 months ago)
- Topics: android, lib, libtdjson, maven, prebuilt, tdjson, tdlib, telegram, telegram-api
- Language: C++
- Homepage:
- Size: 85.9 KB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# android-libtdjson
[![Releases](https://github.com/up9cloud/android-libtdjson/actions/workflows/main.yml/badge.svg)](https://github.com/up9cloud/android-libtdjson/actions/workflows/main.yml)
Prebuilt [libtdjson](https://github.com/tdlib/td) for Android
`Version` tag is same as the version of tdlib
> Releases
- libs.tar.gz: .so files without jni
- jniLibs.tar.gz: .so files with jni> Packages
- maven
> Supported architectures
| Platform | Architecture | |
| ---------------- | ------------ | --- |
| Android | armeabi-v7a | ✅ |
| | arm64-v8a | ✅ |
| Android emulator | x86 | ✅ |
| | x86_64 | ✅ |## Installation
> Method 1: Download jniLibs
- Download jniLibs.tar.gz (from `Releases`) and extract it to your ./app/`src/main/jniLibs/`
- Copy `./app/src/main/java/io/github/up9cloud/td/JsonClient.java` to your repo> TODO: Method 2: Download .jar
- Download .jar file (from `Packages`) to your ./app/`libs/`
- Be sure "*.jar" is the part of dependencies in your `build.gradle` file```gradle
dependencies {
implementation fileTree(dir: "libs", include: ["*.jar"])
}
```> Method 3: Github Maven
- Add those to your `build.gradle` file
```gradle
repositories {
google()
...
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/up9cloud/android-libtdjson")
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
}
dependencies {
// Modify the version, see release
implementation 'io.github.up9cloud:td:'
}
```- Setup ENVs
```bash
export GITHUB_ACTOR=
export GITHUB_TOKEN=
```Other refs:
- GitHub Docs - [Gradle registry](https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-gradle-registry#installing-a-package)
- [enefce/AndroidLibraryForGitHubPackagesDemo](https://github.com/enefce/AndroidLibraryForGitHubPackagesDemo)## Usage
TODO
## Example
TODO
## Dev memo
### Bump the version of tdlib
- Modify the version for git checkout in `./prepare.sh`
- Modify the getVersionName function in `./app/build.gradle`
- Git commit (message example: `bump td to vx.x.x`)
- Git add tag (`git tag vx.x.x`, the tag version should be same as the version of tdlib)
- Push with tags (`git push && git push --tags`)
- Wait for CI task### Build on local, see `.github/workflows/main.yml` also
```console
$ docker run --rm -it -v `pwd`:/app sstc/android-ndk /bin/bash# ./build.sh
```### Cleanup generated .so files for strip testing
```bash
rm -fr \
./build/jni/**/*.so \
./build/jni/**/td/*.so \
./build/td/**/*.so \
./jniLibs \
./libs./build.sh
```- `.travis.yml`: Travis CI has build time limitation (1 hour), and building this lib needs much more than it, so can't build on it.
## License
MIT
- TDLib license, see [td](https://github.com/tdlib/td)