Telegram Client
For MacOS
Manual steps
- java/scala installed
- cd to the project dir
xcode-select --installbrew install gperf cmake openssl coreutilsbrew cask installcd tdlibrm -rf buildmkdir buildcd buildcmake -DCMAKE_BUILD_TYPE=Release -DOPENSSL_ROOT_DIR=/usr/local/opt/openssl/ -DCMAKE_INSTALL_PREFIX:PATH=../example/java/td -DTD_ENABLE_JNI=ON ..cmake --build . --target installcd ..cd example/javarm -rf buildmkdir buildcd buildcmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=../../../tdlib -DTd_DIR:PATH=$(greadlink -e ../td/lib/cmake/Td) ..cmake --build . --target install
Or using SBT
sbt buildTdLib
For Windows (not tested well)
Presets: PowerShell, bitness is 64
Download and install Microsoft Visual Studio. Enable C++ support while installing.
Download and install CMake; choose "Add CMake to the system PATH" option while installing.
Download and install Git.
Download and install gperf. Add the path to gperf.exe to the PATH environment variable.
Download and unpack PHP. Add the path to php.exe to the PATH environment variable.
Download and install JDK.
Close and re-open PowerShell if PATH environment variable was changed.
Run these commands in PowerShell to build TDLib and to install it to tdlib:
cd tdlibgit clone https://github.com/Microsoft/vcpkg.gitcd vcpkg./bootstrap-vcpkg.bat./vcpkg.exe install openssl:x64-windows zlib:x64-windowscd ..Remove-Item build -Force -Recurse -ErrorAction SilentlyContinuemkdir buildcd buildcmake -A x64 -DCMAKE_INSTALL_PREFIX:PATH=../example/java/td -DTD_ENABLE_JNI=ON -DCMAKE_TOOLCHAIN_FILE:FILEPATH=../vcpkg/scripts/buildsystems/vcpkg.cmake ..cmake --build . --target install --config Releasecd ..cd example/javaRemove-Item build -Force -Recurse -ErrorAction SilentlyContinuemkdir buildcd buildcmake -A x64 -DCMAKE_INSTALL_PREFIX:PATH=../../../tdlib -DCMAKE_TOOLCHAIN_FILE:FILEPATH=../../../vcpkg/scripts/buildsystems/vcpkg.cmake -DTd_DIR:PATH=$(Resolve-Path ../td/lib/cmake/Td) ..cmake --build . --target install --config Release
On this page
Contributors
Created September 29, 2019
Updated October 15, 2019