A plug&play libtdjson.so v1.7.10 built for Raspberry Pi
If you want to build by your own follow these steps:
TDLib
depends on:
- C++14 compatible compiler (Clang 3.4+, GCC 4.9+, MSVC 19.0+ (Visual Studio 2015+), Intel C++ Compiler 17+)
- OpenSSL
- zlib
- gperf (build only)
- CMake (3.0.2+, build only)
git clone https://github.com/tdlib/td.git
cd td
rm -rf build
mkdir build
sudo nano tdutils/CMakeLists.txt
- Now add this instruction
if (CMAKE_HOST_SYSTEM_NAME MATCHES "NetBSD")
target_link_libraries(tdutils PUBLIC /usr/pkg/gcc5/i486--netbsdelf/lib/libatomic.so)
+++ else()
+++ target_link_libraries(tdutils PUBLIC atomic)
endif()
- Now you are able to build
cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX:PATH=../tdlib -DTD_ENABLE_LTO=ON ..
cmake --build . --target prepare_cross_compiling -j $(nproc)
cd ..
php SplitSource.php
cd build
cmake --build . --target install -j $(nproc)
cd ..
php SplitSource.php --undo
cd ..
ls -l td/tdlib
You may have some issues due to low memory on your board: try to increase your SWAP
Tested on:
-
Raspberry Pi 3B+ Linux raspberrypi 5.10.63-v7+ armv7l GNU/Linux
-
Language Python