From 21fcb8a945421ec755f26c1e47d9357b3757856c Mon Sep 17 00:00:00 2001 From: Ben Wiederhake Date: Wed, 8 Dec 2021 12:28:00 +0100 Subject: [PATCH] Provide a single script that does everything Also, hardcode the tdlib version, because only one works --- build_and_install.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 build_and_install.sh diff --git a/build_and_install.sh b/build_and_install.sh new file mode 100755 index 0000000..d9f54bb --- /dev/null +++ b/build_and_install.sh @@ -0,0 +1,24 @@ +#!/bin/bash + +set -e + +JOBS="$(nproc || echo 1)" + +rm -rf build +mkdir build +pushd build + git clone https://github.com/tdlib/td.git + pushd td + git checkout 7d41d9eaa58a6e0927806283252dc9e74eda5512 # v1.7.9 wasn't properly tagged + mkdir build + pushd build + cmake -DCMAKE_BUILD_TYPE=Release .. + make -j "${JOBS}" + make install DESTDIR=destdir + popd + popd + cmake -DTd_DIR="$(realpath .)"/td/build/destdir/usr/local/lib/cmake/Td/ -DNoVoip=True .. + make -j "${JOBS}" + echo "Now calling sudo make install" + sudo make install +popd