From efb4f1288438478ea4b08eb93a18fe4252d682cc Mon Sep 17 00:00:00 2001 From: sadlerm4 Date: Thu, 13 Feb 2025 02:04:05 +1100 Subject: [PATCH] chore(tdlib): backport #3196 and bump version (#3296) * fix: tdlib (#3196) * fix: tdlib * remove nightly label * cp examples folder instead of install * remove stray merge conflict text * missing space * bump: tdlib --------- Co-authored-by: Raboneko --- anda/lib/tdlib/anda.hcl | 3 --- anda/lib/tdlib/tdlib-nightly.spec | 28 ++++++++++++++++------------ anda/lib/tdlib/update.rhai | 13 ++++++------- 3 files changed, 22 insertions(+), 22 deletions(-) diff --git a/anda/lib/tdlib/anda.hcl b/anda/lib/tdlib/anda.hcl index 29e7eebe8d..b1b0aee448 100644 --- a/anda/lib/tdlib/anda.hcl +++ b/anda/lib/tdlib/anda.hcl @@ -2,7 +2,4 @@ project pkg { rpm { spec = "tdlib-nightly.spec" } - labels { - nightly = "1" - } } diff --git a/anda/lib/tdlib/tdlib-nightly.spec b/anda/lib/tdlib/tdlib-nightly.spec index cf857c2063..1bef313271 100644 --- a/anda/lib/tdlib/tdlib-nightly.spec +++ b/anda/lib/tdlib/tdlib-nightly.spec @@ -1,15 +1,15 @@ -%global commit 2be9e799a2bc523550d4f83f4d2d66d41c9573b9 -%global ver 1.8.42 -%global commit_date 20240219 +%global commit 8e29c4d7d21db3ab2c7a88c384626e95ef789f61 +%global ver 1.8.45 +%global commit_date 20250212 %global shortcommit %(c=%{commit}; echo ${c:0:7}) -Name: tdlib-nightly -Version: %ver^%commit_date.%shortcommit -Release: 2%?dist -License: BSL-1.0 -URL: https://github.com/tdlib/td -Summary: Cross-platform library for building Telegram clients -Source0: %url/archive/%commit/tdlib-%commit.tar.gz +Name: tdlib-nightly +Version: %ver^%commit_date.%shortcommit +Release: 1%?dist +License: BSL-1.0 +URL: https://github.com/tdlib/td +Summary: Cross-platform library for building Telegram clients +Source0: %url/archive/%commit/tdlib-%commit.tar.gz BuildRequires: gperftools-devel BuildRequires: openssl-devel @@ -20,7 +20,7 @@ BuildRequires: gperf BuildRequires: cmake BuildRequires: gcc -Provides: bundled(sqlite) = 3.31.0 +Provides: bundled(sqlite) = 3.31.0 %description TDLib (Telegram Database library) is a cross-platform library for @@ -62,14 +62,18 @@ sed -e 's/"DEFAULT"/"PROFILE=SYSTEM"/g' -i tdnet/td/net/SslStream.cpp %install %cmake_install -mv LICENSE_1_0.txt *.md .. +mv LICENSE_1_0.txt *.md example .. rm -rf * mv ../LICENSE_1_0.txt ../*.md . +mkdir -p %buildroot%_datadir/%{name} +cp -r ../example %buildroot%_datadir/%{name} + %files %license LICENSE_1_0.txt %doc README.md CHANGELOG.md %_libdir/libtd*.so.%ver +%_datadir/%{name}/example/* %files devel %_includedir/td diff --git a/anda/lib/tdlib/update.rhai b/anda/lib/tdlib/update.rhai index 0e2cafa333..1e0532fd66 100644 --- a/anda/lib/tdlib/update.rhai +++ b/anda/lib/tdlib/update.rhai @@ -1,8 +1,7 @@ -if filters.contains("nightly") { - rpm.global("commit", gh_commit("tdlib/td")); - if rpm.changed() { - let v = find("\nproject\\(TDLib\\s+VERSION\\s+([\\d.]+)\\s+", gh_rawfile("tdlib/td", "master", "CMakeLists.txt"), 1); - rpm.global("ver", v); - rpm.release(); - } +rpm.global("commit", gh_commit("tdlib/td")); +if rpm.changed() { + let v = find("\nproject\\(TDLib\\s+VERSION\\s+([\\d.]+)\\s+", gh_rawfile("tdlib/td", "master", "CMakeLists.txt"), 1); + rpm.global("ver", v); + rpm.release(); + rpm.global("commit_date", date()); }